How do I query for ANY alphanumeric contents in a custom metadata field?

I deleted meta data that was no longer necessary some months ago. My goal was to get completely rid of it, as if I never used it. If I recall correctly it wasn’t sufficient to just delete meta data from those records that I assigned meta data to, I had to process all records even those where I was pretty sure they never had this meta data assigned.

To do this you’ll need to

  • install List & Record Tools

  • get the meta data identifiers

    • either via the helper script (which I suggest)
    • or by looking it up in Preferences > Data. There’s no way to copy identifiers from preferences, so make sure you don’t have typos. Also make sure to prefix each meta data identifier with md.
  • set the identifiers in the main script

  • run the main script

  • run the other helper script to check if everything was removed. It creates a text file on your desktop - if everything worked fine the meta data shouldn’t show up there.

Here are the scripts Delete custom metadata fields.

I think I also removed the meta data afterwards from the plist but can’t recall if it was necessary.