Overview: Query Builder for HubSpot Marketing (Contact Properties)

With the Query Builder for HubSpot Marketing (Contact Properties), you can use Custom Contact Properties and a combination of metrics, dimensions, and filters to create Custom Metrics in Databox.  

HOW TO

How to access the Query Builder for HubSpot Marketing (Contact Properties)

Navigate to  Metrics > 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 Contact Properties radio button.

    Query Builder is available on the Professional and Performer plans. Request a trial of Query Builder by following these steps

How to use the Query Builder for HubSpot Marketing (Contact Properties)

A
  Data Source: This is the Data Source that the Custom Metric is syncing data from (HubSpot Marketing). 
B
  Metric: Select a Metric from your connected HubSpot Marketing Data Source, such as "Count of Contacts," or any other Custom Contact Property. Selecting the Metric will expose the Dimension field. 
C
  Dimension (Optional): The Dimensions parameter re-categorizes the returned Metric value based on common criteria. An example of Dimension is "HubSpot Team," or any other Custom Contact Property. 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 Metric "Count of Contacts by HubSpot Team."      
D

  Date Field: The Date Field determines which Contacts will be included in the Custom Metric. For example, if "Create Date" is selected, any Contacts Property created during the specified Date Range(s) will be included in the Custom Metric. If a custom Date Field is selected, any Contact Property that matches the selected criteria during the specified Date Range(s) will be included in the Custom Metric.  

E
  Filter by (Optional):  Filters restrict the data that gets included in the Custom Metric. All data that is returned is tested against the Filter(s). Multiple Filters can be combined using AND / OR boolean logic. 
If the data synced from the Metric and Dimension fields meet the Filter specifications, the data is retained and included in the Custom Metric value. If the data synced from the Metric and Dimension fields don't meet the Filter specifications, the data is excluded from the Custom Metric value.
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 Account for each field. Learn more here.
Some common Filters include filtering data by ''Company Size'' and ''Contact Owner''.
F
  Invert Metric (Optional): By default, the percentage change value displayed on Datablocks is green when the Metric value has increased, and red when the Metric value has decreased. If the Custom Metric you created has opposite trends, select this option. Learn more here.  
G
  Data Preview: After clicking Preview data, 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 drop-down list at the top of the Data Preview.
H
  Custom Metric Name: Enter a name for your Custom Metric. This Custom Metric name will be available in the Designer after saving. 
I
  Save: Save your Custom Metric. 

How to create a Custom HubSpot Marketing Metric [Example]

In this example, we'll create a Custom Metric to report on the New Contacts by Contact Owner for mid-size Companies.

1
 Navigate to Metrics > Query Builder   
2
 Click the green + New query button
3
 Select the appropriate HubSpot Marketing Data Source 
4
 We will select Count of contacts from the Metric dropdown list, since we want to track the number Contacts
5
 We want to view the associated Contact owner, therefore we'll select Contact owner from the Dimension dropdown list 
6
 We're interested in tracking newe Contacts created, so  Create Date will be our Date Field selection 
7
 Lastly, we want to restrict the Custom Metric to only retain data for the mid-size companies, so we'll add a Filter to the Custom Metric.
First, click on the  Advanced Options hyperlink to open the Filter section of the Query Builder. Click on the  Filter by dropdown and select Company size. Next, click on the  Operator dropdown, and select Greater than. Lastly, in the Value textbox, we'll enter the value = 100.
8
  To accurately explain what this Custom Metric is reporting on, we'll name the Custom Metric ''# of Contacts by Contact Owner (mid-size companies)''
9
 Click Preview data 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 HubSpot Marketing Metric to a Databoard

Learn how to add a Custom Metric to a Databoard here

Additional Information

  • Which fields a Custom Contact Property is available in is dependent on the type of property that's set in HubSpot. Numerical properties (i.e., store values) can be used in the Metric field. Checkboxes, Yes/ No Answers, Dropdowns, or other String properties can be used in the Dimension field or in the Filter. Date properties can be used in the Date Field. 
  • Custom Contact Property type 'File Upload' is not supported in this Query Builder.
Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.