5

I'm receiving a bug from an production enviroment that is totally strange for me. The same query give different results based on the fields present in the query. I give you an example on the query Made:

Select id, LogisticaContatto__c From order  where id='801w0000003OaluAAC'

This Query returns 0 results.

While the same query without the custom field returns correctly the record, as expected.

Select id From order  where id='801w0000003OaluAAC'

the custom field LogisticaContatto__cis an formula field that reads some values via lookup. This is happening with only this field.

I'm not understanding what is happening. Do you have any similar experience and a reasonable logic that this should happen?

The logic on the formula field is this

IF(TEXT(Type__c)='Constant1',
                IF( NOT( ISBLANK(Inst__r.PersonMobilePhone)),Inst__r.PersonMobilePhone,
            IF( NOT( ISBLANK(Inst__r.Phone)),Inst__r.Phone,
                IF( NOT( ISBLANK(Inst__r.PersonHomePhone)),Inst__r.PersonHomePhone,
                    Inst__r.PersonOtherPhone
                )
            )
        )
,
    IF( Account.RecordType.Name ='Business',  Account.Phone ,
        IF( NOT( ISBLANK(Account.PersonMobilePhone)),Account.PersonMobilePhone,
            IF( NOT( ISBLANK(Account.Phone)),Account.Phone,
                IF( NOT( ISBLANK(Account.PersonHomePhone)),Account.PersonHomePhone,
                    Account.PersonOtherPhone
                )
            )
        )
    )
)

thanks.

9
  • 2
    I'm proceeding also to ask to Salesforce support, anyway was a case never seen and i was not able to find corresponding results on web, so i posted it here.
    – Klodj_Meta
    Nov 10, 2016 at 16:40
  • Does the user have permissions over the custom field (LogisticaContatto__c) ?
    – ransommule
    Nov 10, 2016 at 17:04
  • Yes, I'm running as system admin, and i have the permission. Usually if you don't have permission is generated an error.
    – Klodj_Meta
    Nov 10, 2016 at 17:06
  • Did you run both query in developer console ? Same result ?
    – ransommule
    Nov 10, 2016 at 17:08
  • have you checked the logs of the developer console, perhaps it is thowing an exception ?
    – ransommule
    Nov 10, 2016 at 17:10

1 Answer 1

4

I opened a case with support about this yesterday. It has been acknowledged as a bug and they will be rolling back the patch that caused it.

5
  • did they provide any additional detail as to what caused it?
    – Eric
    Nov 11, 2016 at 1:13
  • 1
    Nothing other than that a recent patch caused the problem. I noticed the issue in my sandboxes yesterday and then in my production org today. I just received confirmation (and tested for myself) that the issue is resolved in my sandbox. still occurs in my production org though.
    – mkdjns
    Nov 11, 2016 at 1:23
  • Thanks for the follow up on this question. Interesting bug or was it WAD but just designed poorly...hmmm.
    – Eric
    Nov 11, 2016 at 1:30
  • I also opened a bug, I'm waiting a feedback from them. @mkdjns can you give your case id or case number, so i can share directly to support to boost the solution? Thnks.
    – Klodj_Meta
    Nov 11, 2016 at 13:12
  • 1
    My case number is 15090902.
    – mkdjns
    Nov 11, 2016 at 14:59

You must log in to answer this question.

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