SOQL Studio 2021 – Drill Down into Child Objects in the Org Schema

In my Sneak Peek post for SOQL Studio 2021.2, I showed a screen shot of the updated Organizations tool window that included schema filtering and reference field drill down. My last post focused on the new schema filtering capability. In this post, I’m going to talk about the reference field drill down capabilities that we built.

Organizations Tool Window showing reference field drill down

In the screen shot above, you can see the the License__c custom object has been expanded to show all its fields and that LastModifiedById, which is a reference field, has also been expanded to reveal the refenced object (User). That in turn has been expanded to reveal its fields. One of the features we’re excited about is that this drill down capability doesn’t stop at the first reference level. We put no limits on the depth to which you can drill down. In the screen shot above, the AccountId field in the User object is a reference field to Account and can be expanded. Account has its own reference fields that can be expanded, and so on.

If the reference field is polymorphic, like GroupMember’s UserOrGroupId field, you’ll see each object that it can reference listed. The screen shot below shows the GroupMember’s UserOrGroupId field expanded to show that it can reference the Group and User objects.

Polymorphic Reference Field Example

Dragging a field from the Organizations tool window into a SOQL editor has always added that field at the location where it’s dropped. With fields from a reference object, in addition to the field itself the full reference chain back to the primary object it was pulled from is included. In the first screen shot above, if AccountId was expanded to reveal the Account object and the account Name field was dragged into a SOQL editor, the resulting field would be ‘LastModifiedBy.Account.Name’. SOQL Studio takes care of looking up all the required relationship names and prepending them to the field for inclusion in a SOQL query.

Conclusion

The ability to drill down into a reference field’s object is a useful tool for SOQL Studio users, providing a fast, efficient way to find fields in the schema and add them to a query. But there’s still more to this release, and I’ll get into some of that in my next post. For now, I just wanted to preview this feature that’ll be coming to SOQL Studio later this summer.

More Information

Learn more about SOQL Studio by visiting our website.  If you’ve never tried SOQL Studio, or tried an older version, we encourage you to start a 30-day free trial of SOQL Studio 2021.1 today!

Free Upgrade

Current customers with an active maintenance contract are entitled to a free upgrade.  Login to you account, go to Downloads & Licenses and click the “Request Upgrade” button.  You’ll be emailed a new license for version 2021.1 and you can download the new package right from there.