How do I pull Salesforce data for an individual account?
This Transform represents an individual account, which is an organization or person involved with your business.
This Transform pulls out some of the most important fields from the "account" table in Salesforce.
-- This Transform represents an individual account, which is an organization or person involved with your business.
-- This Transform pulls out some of the most important fields from the "account" table in Salesforce. It is used in 5 other prebuilt Salesforce Transforms:
-- - prebuilt__salesforce_opportunity_enhanced
-- - prebuilt__salesforce_opportunity_aggregation_by_owner
-- - prebuilt__salesforce_manager_performance
-- - prebuilt__salesforce_owner_performance
-- - prebuilt__salesforce_sales_snapshot
-- You can use this Transform as the basis for other analyses you'd like to do on Salesforce "account" data.
with account as (
select
_fivetran_synced,
account_source,
billing_city,
billing_country,
billing_postal_code,
billing_state,
billing_street,
description,
id as account_id,
industry,
is_deleted,
last_activity_date,
last_referenced_date,
last_viewed_date,
master_record_id,
name as account_name,
number_of_employees,
owner_id,
parent_id,
shipping_city,
shipping_country,
shipping_postal_code,
shipping_state,
shipping_street,
type,
website
-- You can add more fields from the Salesforce "account" table that haven't been included above here.
from salesforce.account
)
select *
from account
-- This excludes any results that have been deleted from the Transform output.
where not coalesce(is_deleted, false)
LIMIT 100