Skip to main content
Conga Support

Convert Data Gathering Reports to Conga Queries

Salesforce reports used to gather data for Conga templates must be converted to Conga Queries to work in Salesforce Lightning. Conga templates that merge data from those reports must also be updated.

Converting reports to queries involves three steps:

  1. Use the Conga Query Builder to re-create the report.
  2. Add the query to the Composer solution using an alias.
  3. Update affected templates.

In this example, we are going to convert a Salesforce report that gathers data about Contacts related to an Account for an Account Summary solution.  In general, you can use these same steps to convert any reports you are using to gather data for Conga Composer.

Use the Conga Query Builder to Recreate the Report

The Conga Query Manager and Conga Query Builder are custom objects installed with the Conga Composer package. They assist with the creation of SOQL queries for use with Conga Composer. The steps below outline how to write a query using the Conga Query Builder.

  1. Navigate to the Conga Queries object (go to All Tabs, which is the "+" in the ribbon, and then select Conga Queries from the list).
  2. Click New.
  3. Give the new query record a name. In our example, we are converting a report that gathers Contact data for an Account Summary solution, so we will name our query Account Summary - [Contacts].
  4. Click Save.
  5. Next, click Conga Query Builder. The Conga Query Builder is going to walk you through four steps to write the query.


     
  6. Select the base object. This is the lowest-level object. For our example, we are gathering Contact data related to an Account, so Contact is our base object. Select Contact and click Next.


     
  7. Select columns. These are the fields you want to merge into your Conga template. In our example, the report we are replacing currently merges First Name, Last Name, Title, and Phone, so we are going to add those same four columns. Search for and select the columns from the list, then click the right-facing arrow to move each one over to the Selected Fields pane. Click Next.


     
  8. Choose a selection criteria. This is the equivalent of adding a blank Master Object ID filter to your report. Choose your Master Object Id from the first field drop-down list. In our example, it is Account ID. As you do with reports, leave the Operator as equals and the value blank. Click Next.


     
  9. (Optional) Test the results. If you would like to test the results of the query, you can paste a sample Master Object ID into the pv0 field. We will test our query later, so we will skip this step and instead click Save.


     

Notice your new SOQL statement populated in the SOQL Select Statement field on the Conga Query record:


We are now ready to add this Conga Query to our Composer solution.  Go to the next step.