Is there any way to cause a triggering event on custom metadata types? I know there is this idea, which is not implemented.

I have a use case where I need a country list stored (can create custom MDT) Now these countries can have a risk factor associated and that can change so whenever the Custom MDT changes, it should also update the records which uses the specific country metadata type.

Anyone did any clever solution to track changes on Custom metadata types?

1 Answer 1


Instead of Custom metadata you can use Custom object.

Orelse, if you really need it, you can write a Batch which runs every 15 minutes. You can store the current instance of Custom metadata record in a local variable and on each start first query these records from Custom metadata and check if the local instance is same as queried instance.

If changed then in same start, return a query on records to be changed, and then change your records in execute.

You can schedule this job to run every 15 minutes or so. You can decide on this time based on your org Batch processing load. You can either reduce this to every minute or increase it to every hour.

NOTE: This should only be done if there is no way to move the logic from metadata to object.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .