"SEL*" wrongly pulling in relationships

11 views
Skip to first unread message

RonSFDev

unread,
Oct 7, 2024, 9:35:16 AM10/7/24
to Illuminated Cloud Q&A
I'm a longtime lover of building SOQL with "SEL*".  In recent months when I use this, all the fields from the SObject are pulled in to the query automatically.  But now it also adds "Owner", "CreatedBy" and "LastModifiedBy" along with OwnerId,  CreatedById and LastModifiedById.

If you run the query exactly as it is generated, then you get an error because there's no column named "Owner", etc.  So then I have to manually delete those every single time.  Am I the only one who's noticed this behaviour?  Or is it some new feature I can shut off?

Scott

unread,
Oct 7, 2024, 9:36:19 AM10/7/24
to Illuminated Cloud Q&A, RonSFDev
Hi. That sounds like a bug, and I think I may even know the change that might have introduced it. I'll take a look and, assuming I can reproduce it, I'll implement a fix for this week's build. Apologies for the inconvenience, and thank you for bringing it to my attention.

Regards,
Scott Wells

Scott

unread,
Oct 8, 2024, 9:36:16 AM10/8/24
to Illuminated Cloud Q&A, Scott, RonSFDev

Hi. I just tried reproducing this and wasn’t able to do so. I tried with standard objects (Account), custom objects, and Tooling API objects, and in all cases (for me), SEL* generated a valid query without the relationship targets included.

Specifically what kinds of queried objects are resulting in this behavior for you? Can you try using File | Invalidate Caches and see if the behavior persists after restarting and reindexing completes?

Regards,
Scott Wells

Reply all
Reply to author
Forward
0 new messages