0

I have an issue with Workbench. I can't retrieve Entitlement Process (somecomponent__process), if this Entitlement Process contains "__" in name.

I try to retrieve here: Workbench Retrieving

Single package checked.

Using XML like this:

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

And I am getting this error:

Error in Workbench

But this component exists on organisation.

this component in org

I have tried different ways to solve it. I tried to retrieve all components, and it works. But when I copy the name of component and trying to retrieve only 1 component, it fails.

4
  • Does it work using another tool? The quirk could be unique to Workbench and not the Metadata API. But generally speaking I would avoid using double underscores in Salesforce API names because they're auto appended to most API names (like __c, __mdt, __share, __feed etc.)
    – nbrown
    Mar 28 at 18:45
  • Search for "two consecutive underscores" Metadata Api Salesforce and you will find numerous examples for (developer and other) names that are not allowed to contain two consecutive underscores. I'd not be surprised, if you see an explicit error message using the migration tool. Mar 28 at 21:26
  • brown, I didnt try to use another tool. thanks! Mar 29 at 9:29
  • Felix van Hove thank you for answer! Mar 29 at 9:29

1 Answer 1

1

Was able to replicate the issue with Metadata API tools (ANT, Workbench) and I see similar error and below is xml package. You can encode '_' with '%5f'.

    <types>
        <members>somecomponent%5F%5Fprocess</members>
        <name>EntitlementProcess</name>
    </types>
    <version>54</version>

This seem to be working as designed, As a workaround use single underscore like <members>somecomponent%5Fprocess</members> or <members>somecomponent_process</members> instead and you should be able to retrieve successfully.

Thanks

4
  • thank you! I tried this way, but it also doesnt work. " I tried to retrieve all components, and it works. But when I copy the name of component and trying to retrieve only 1 component, it fails.". Here when I retrieved all components, this component was with "%5F" in the Name. But it doesnt work. Apr 11 at 11:57
  • I was able to retrieve successfully using '<members>somecomponent%5Fprocess</members>' tag, can you try in another org also use system admin profile to retrieve metadata.
    – Vinay
    Apr 12 at 5:37
  • No, I have two __, not one _ in the name of the component. In my case the name of the component will be somecomponent%5F%5Fprocess. There is added more one %5F Apr 12 at 10:18
  • Yes, this seem to be expected behavior for double __, try using single underscore.
    – Vinay
    Apr 12 at 14:19

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.