SOQL record card – user guide

SOQL record card is a reusable LWC component UX element which offers you the ability to pull up a field information from current record, or related record or other records with help of a SOQL query.

This SOQL queries are stored in objects SOQL Query, with a query name which is provided as the LWC component property while adding to lightning flexi-pages – simple home page, record page or even digital experience page.

Write queries targeting on the field of concern which you want to pull up (without using LIMIT and OFFSET). Make use of subqueries, joins, etc. creatively to get the insight that helps your reps achieve tasks faster.

It’s not just about field info, if it’s a record query other than a field from current record, it will show you an EYE icon which will navigate you to the record just like a standard lookup field.

You can make use of ‘#currentUserId#’ to fetch and display record related to current user. Similarly you can even use the ‘#recordId#’ in your SOQL query to refer record ID of current record when using the component on lightning record page.

As SOQL queries are stored in a Custom Object, you can even apply Salesforce Security settings on your queries in addition to the security setup that you have configured for the underlying object that you are querying.

You can also club this with OOB conditional rendering of component instances, you customise the page experience respective to your business user groups.

So basically this a like a LEGO block which will help you pull up the most critical record or field from the record helping users switch between relevant business records faster.

Steps to install:

  1. Get the app from here: https://appexchange.salesforce.com/appxListingDetail?listingId=a0N4V00000FN8LNUA1&channel=recommended
  2. SOQL query admin permission set available is available in the package which can enable full access to manage SOQL query records for any non-admin users incase you need it.
  3. Find the SOQL Queries tab > add your SOQL query record with a unique & manageable query name.
    Recommend a query name which is easy to organise & maintain your queries in a way that you can further use it with list view filters, sharing rules, etc.
  4. Open the target Lightning page where you want to add the SOQL card > drag-drop the SOQL Record Card component from available list of custom components > Add the target query name along with other details.