Salesforce connector: datasets and metric definitionsBeta
Bring in leads, opportunities, stage history, accounts and campaigns. Updates daily. Needs Salesforce Enterprise edition or above; your Salesforce admin installs the Quiriz package once.
When you connect Salesforce, Quiriz imports the datasets below and adds the metric definitions to Company Context, the one place your company’s definitions live. Every answer that uses one of these metrics uses the same definition, in the app, in Slack and in the Excel, Sheets, PowerPoint, Slides, Word and Docs add-ins. An admin can edit any of them.
DatasetsMetric definitionsQuestionsFAQ
Datasets
| Dataset | What it holds |
|---|---|
| [Salesforce] Leads | Leads19 columnslead_id, created_date, status, status_order, is_converted, converted_date, days_to_convert, converted_opportunity_id, converted_account_id, lead_source, owner, company, industry, country, state, rating, record_type, fiscal_year, fiscal_quarter |
| [Salesforce] Lead status history | Lead status history7 columnslead_id, status, status_order, entered_date, left_date, days_in_status, is_converted_status |
| [Salesforce] Opportunities | Opportunities28 columnsopportunity_id, name, account_id, account_name, owner, pipeline, record_type, type, stage, stage_order, is_closed, is_won, probability, forecast_category, amount, currency, amount_corporate, expected_revenue_corporate, weighted_amount_corporate, created_date, close_date, days_to_close, days_since_stage_change, lead_source, primary_campaign, is_from_lead, fiscal_year, fiscal_quarter |
| [Salesforce] Opportunity stage history | Stage history13 columnsopportunity_id, pipeline, stage, stage_order, is_closed, is_won, entered_date, left_date, days_in_stage, amount_corporate_at_entry, close_date_at_entry, probability_at_entry, forecast_category_at_entry |
| [Salesforce] Pipeline snapshots | Pipeline snapshots9 columnssnapshot_date, opportunity_id, pipeline, stage, stage_order, amount_corporate, close_date, forecast_category, owner |
| [Salesforce] Accounts | Accounts10 columnsaccount_id, name, type, industry, billing_country, billing_state, employees, annual_revenue_corporate, owner, created_date |
| [Salesforce] Campaigns | Campaigns16 columnscampaign_id, name, type, status, parent_campaign, start_date, end_date, is_active, budgeted_cost, actual_cost, leads, converted_leads, opportunities, won_opportunities, amount_all_opportunities, amount_won_opportunities |
Metric definitions
Each metric is a total over the period you ask about. A metric built from other metrics, such as a rate, divides the totals for the whole period; it does not average daily rates. Dated by is the date column that decides which period a row belongs to.
[Salesforce] Leads
| Metric | How it is calculated | Dated by | Notes |
|---|---|---|---|
| Salesforce leads created | Count of distinct lead_id | created_date | Leads created, by create date. Group by lead_source for where they came from. |
| Salesforce lead conversion rate | Share of rows where is_converted is 1 | created_date | Converted leads divided by leads created, by create date. Shown as a decimal (0.25 = 25%). |
| Salesforce days to convert | Average of days_to_convert, where is_converted = 1 | converted_date | Mean days from lead creation to conversion, by convert date. |
[Salesforce] Opportunities
| Metric | How it is calculated | Dated by | Notes |
|---|---|---|---|
| Salesforce pipeline value | Sum of amount_corporate, where is_closed = 0 | created_date | Open opportunity amount in the corporate currency, by create date. Group by pipeline when the dataset has a pipeline column (the org has more than one sales process). |
| Salesforce weighted pipeline | Sum of weighted_amount_corporate, where is_closed = 0 | created_date | Open opportunity amount times probability, in the corporate currency, by create date. Group by pipeline when the dataset has a pipeline column (the org has more than one sales process). |
| Salesforce win rate | Share of rows where is_won is 1, where is_closed = 1 | close_date | Won opportunities divided by closed ones, by close date. Shown as a decimal (0.25 = 25%). Group by pipeline when the dataset has a pipeline column (the org has more than one sales process). |
| Salesforce average deal size | Average of amount_corporate, where is_won = 1 | close_date | Mean amount of won opportunities in the corporate currency, by close date. |
| Salesforce closed won revenue | Sum of amount_corporate, where is_won = 1 | close_date | Amount of won opportunities in the corporate currency, by close date. |
| Salesforce sales cycle days | Average of days_to_close, where is_won = 1 | close_date | Mean days from create to close for won opportunities, by close date. |
| Salesforce lost deals | Count of distinct opportunity_id, where is_closed = 1 AND is_won = 0 | close_date | Opportunities closed and not won, by close date. |
| Salesforce stalled deals | Count of distinct opportunity_id, where is_closed = 0 AND days_since_stage_change > 30 | Today’s snapshot | Open opportunities with no stage change in over 30 days. Group by stage. Group by pipeline when the dataset has a pipeline column (the org has more than one sales process). |
[Salesforce] Opportunity stage history
| Metric | How it is calculated | Dated by | Notes |
|---|---|---|---|
| Salesforce average days in stage | Average of days_in_stage | entered_date | Mean days an opportunity spent in a stage, by the date it entered. Group by stage. Group by pipeline when the dataset has a pipeline column (the org has more than one sales process). |
| Salesforce deals entering stage | Count of distinct opportunity_id | entered_date | Opportunities that entered a stage, by entry date. Next stage divided by this stage is the stage conversion rate. Group by pipeline when the dataset has a pipeline column (the org has more than one sales process). |
[Salesforce] Pipeline snapshots
| Metric | How it is calculated | Dated by | Notes |
|---|---|---|---|
| Salesforce open pipeline as of | Sum of amount_corporate | snapshot_date | Open pipeline in the corporate currency on a snapshot date. Filter to one snapshot_date (or compare two); summing across dates double-counts. Group by pipeline when the dataset has a pipeline column (the org has more than one sales process). |
[Salesforce] Campaigns
| Metric | How it is calculated | Dated by | Notes |
|---|---|---|---|
| Salesforce campaign cost | Sum of actual_cost | start_date | Actual campaign cost, by campaign start date. |
| Salesforce campaign won deals | Sum of won_opportunities | start_date | Won opportunities credited to the campaign (Salesforce's all-time roll-up), by campaign start date. |
| Salesforce campaign cost per won deal | Salesforce campaign cost ÷ Salesforce campaign won deals | start_date | Actual campaign cost divided by the won opportunities credited to the campaign. |
Questions to ask
- What's the state of our funnel this quarter?
- How many leads came in each month this year, by source?
- What's our lead conversion rate by source?
- How much pipeline is in each stage right now?
- Where are deals stalling?
- What's our win rate by owner this year?
- How has open pipeline changed since last month?
- Which campaigns produced the most won revenue?
Related guides
- CRM Reporting for HubSpot and Salesforce: Win Rate and Pipeline
- Why Your Win Rate Keeps Changing (Three Definitions, One Word)
Ask Salesforce in plain words
Try the questions on sample data with no signup, then connect Salesforce read-only and ask your own.
Try Quiriz free →Frequently asked questions
Does Quiriz change anything in Salesforce?
How often does the Salesforce data refresh?
Can I change how a metric is calculated?
Can I combine Salesforce with other sources?
All connectors: Quiriz connectors. Definitions on this page are generated from the product’s own connector code.