We need to delete inactive values from some of our picklist using ant and we are not able to do it.

We have tried with this 'destructivePackage.xml':

<?xml version="1.0" encoding="UTF-8"?>
<Package xmlns="http://soap.sforce.com/2006/04/metadata">

It seems it is working to move active values to inactive values, but not to delete the inactive value.

Any solution?

  • Is it possible that there is a record with the given value of picklist? – kurunve Aug 28 '18 at 8:35
  • yeah, in this case the inactive value is 'Hola'. – lopez.regalado.fj Aug 28 '18 at 8:38

Deleting picklist values operation is not supported by Salesforce METADATA API

This is because of when we delete any picklist value by UI we need to set replacement of that value in records i.e. Blank or Any other picklist value.

Reference - https://blog.jeffdouglas.com/2008/07/15/migrating-salesforcecom-configurations-with-the-metadata-api-forcecom-migration-tool/


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.