Overview: Query Builder for HubSpot Marketing (Contacts)

HOW TO

How to access the Query Builder for HubSpot Marketing (Contacts)

Navigate to   Data Manager > Query Builder to access the Query Builder for HubSpot Marketing. Click the green + Create Custom Metric button and select your connected HubSpot Marketing Account from the Data Source drop-down list. Select the Contacts button. 

    Query Builder is available in Plus and Business Accounts. Agency Basic Accounts have access to Query Builder in the Agency Account only.  Request a trial of Query Builder by following these steps.  

How to use the Query Builder for HubSpot Marketing (Contacts)

A
   Custom Query Name: Enter a name for your Custom Metric. This Custom Metric Name will be available in the Designer after saving.
B
   Metric: Select a Metric from your connected HubSpot Marketing Data Source, such as "Became an Opportunity," "Became a Marketing Qualified Lead" or "Became a Customer." 
C
   Dimension(Optional): The Dimensions parameter re-categorizes the returned Metric value based on common criteria. For this Query Builder, Original Source, Owner, and HubSpot Team ID are Dimension options. If no Dimension is selected, the Custom Metric will store 1 aggregated Metric value for each Date Range. 
Pro Tip: Add the word "by" in between the Metric and Dimension in order to determine an appropriate Custom Metric Name. From the Metric and Dimension examples outlined above, we could create the Custom Metrics "Became an Opportunity by Original Source," "Became a MQL by Owner," and "Became a Customer by HubSpot Team ID." 
D
   Date Range: Select up to 8 Date Ranges that will be available for the Custom Metric. The Date Ranges selected are the only periods of time that data is synced for this Custom Metric. 
E
  Compare With(Optional): Select a comparison period to measure each Date Range against, like Previous Period or Same Period Last Year. Data for the comparison period will be synced for each Date Range that is selected. 
F
   Data Preview: After clicking  Run query, a Data Preview of the Custom Metric will be displayed. Daily Metric values are displayed in this section, along with the total Metric values for the Date Range in bold at the bottom. You can view the Data Preview for different Date Ranges by clicking on the tabs at the top of the Data Preview. 
Pro Tip : If you don't know which Filters to put in place for your use case, use the Dimension + Data Preview to troubleshoot and get more insight into the data that is returned from your HubSpot CRM Account for each field. Learn more here.

How to create a Custom Contacts Metric [Example]

In this example, we'll create a Custom Metric to track Contacts who Became a Lead, split up based on the Original Source. 

1
 Navigate to  Data Manager > Query Builder    
2
 Click the green  + New query button 
3
 Select the appropriate HubSpot Marketing Data Source and the Contacts button 
4
 In order to accurately explain what this Custom Metric is reporting on, we'll name the Custom Metric  Became a Lead by Original Source
5
 We will select  Became a Lead from the  Metric dropdown list, since we want to track the total amount of Contacts who entered the "Lead" Lifecycle Stage. 
6
 Since we want to view the Original Source where the Lead was generated, we'll select Original Source from the Dimension drop-down list.
7
 Next, we'll select the Date Range options for our Custom Metric. We set monthly Goals that are reviewed weekly, so we will choose   Last Month, Month to Date, Last Week, and   Week to Date as  Date Range selections 
8
 We want to view our performance against the previous period, so we'll select  Previous Period as the  Compare With value
9
 Click  Run query to generate a Data Preview of the Custom Metric
10
 Once we confirm that these are the results we're looking for, we'll click  Save to save the Custom Metric

How to add a Custom Contacts Metric to a Databoard

1
 Open the selected Databoard in the Databox Designer, or create a new Databoard.  
2
 Drag and drop a blank Datablock onto the Databoard from the Visualization Library. 
3
 Select the appropriate HubSpot Marketing Data Source from the righthand  Datablock Settings panel. This must be the same HubSpot Marketing Account that was selected when creating the Custom Metric.   
4
 Select the   Custom tab at the top of the   Metric drop-down list. 
5
 Select the Custom Metric name to populate the Datablock.

Additional Information

  • If there is no data returned for the specified Date Range(s), no data will be displayed in the Data Preview.
  • Daily data is not available for Custom Metrics created through this Query Builder. Because of this, you will want to view your Custom Contacts Metrics on a Visualization Type that does not necessitate granularity options. Line Charts and Bar Charts will not be good Visualization Types for this data, but Tables, Pie Charts, and Number Blocks will be.
Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.

Still need help? Contact Us Contact Us