Create a Query

A query contains the pieces of information needed to retrieve desired information in Nimble AMS.

  1. In the tab bar, click  App Launcher, or in Salesforce Classic, click  Nimble AMS, Staff View, Button, All Tabs
  2. Click Queries.
  3. Click New.
  4. In Query Name, enter an easily recognizable term to identify this query written in Pascal Case.

    If you have multiple Community Hubs, and intend to use a similar query in each, we recommend you name each after the Community Hub in which it will be used, so you can distinguish them.

  5. In SELECT, enter the fields you want returned by your query, separated by a comma.
  6. In SObject, enter the name of the object from which you want the fields queried.
  7. Optionally, in WHERE, enter the conditions that must be met in order for records to be returned by your query.

    If you have multiple Community Hubs, keep in mind whether the query should filter for only records associated with the entity(s) for the Community Hub in which this query will be used, or if you want to return records from all entities. To return only records for the current entity, include Id = {!CurrentEntityId} in the WHERE clause.

  8. Optionally, in ORDER BY, enter how you would like the resulting records to be ordered.
  9. Optionally, in LIMIT, enter the number maximum number of records to be returned by your query.

    LIMIT is set by default to 50,000, which is the maximum number of results Salesforce will return to a query. It's recommended that you set the value to 50,000 or below, since there will be an error if more than 50,000 results are found.

  10. Click Save.

In This Section