I setup a field in Salesforce:

enter image description here

When looking at the metadata for my custom object containing this field, this is the data on that metadata field:

    "defaultValue": null,
    "defaultedOnCreate": true,
    "name": "ABI__c",

Why is the defaultValue null? Shouldn't it be false?

Using REST API v31.0

I tried defaulting the value to true/checked, but the defaultValue is still null.

This issue still exists in REST API v32.0

  • The problem is that a NULL and a FALSE checkbox value appear the same and can both be described as Unchecked. The more important question is what problems are you running into as a result of the NULL values. – Joseph U. Nov 12 '14 at 20:53
  • @JosephU. thanks for the feedback. However, I tried setting the default value to true, and it is still null. (I posted a minor edit to my question saying so.) – contactmatt Nov 12 '14 at 21:07
  • 1
    Vote up this idea: success.salesforce.com/ideaview?id=08730000000HXSiAAO – Mark Masterson Nov 13 '14 at 22:44
  • @MarkMasterson thanks for the link, I upvoted the issue. I can't believe this bug has been around for years! – contactmatt Nov 13 '14 at 22:59

There doesn't appear to be a way to get the default programmatically at this time, but there is an idea to get this changed.

Update: As noted in the idea comments, this has now grown up and become a real Known Issue/Bug.

  • The sad truth :/ – contactmatt Nov 18 '14 at 20:23

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.