You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/unified-profiles/create-sql-traits.md
+10-6Lines changed: 10 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,8 +1,8 @@
1
1
---
2
-
title: RETL Scripts For Importing Salesforce Objects Into Unified Profiles in Flex
2
+
title: RETL Queries for Importing Salesforce Objects Into Unified Profiles in Flex
3
3
hidden: true
4
4
---
5
-
Unified Profiles in Flex users can convert Salesforce objects with US phone number patterns (typically (555) 231-7654) into Segment Unify profiles with E.164 phone number formats (+15552317654)to support Unified Profiles lookup.
5
+
You can use the following SQL queries to convert Salesforce objects with US phone number patterns (typically (555) 231-7654) into Segment Unify profiles with E.164 phone number formats (+15552317654). Unified Profiles in Flex requires phone numbers used for profile lookups to be in E.164 format.
6
6
7
7
Segment created three sample queries for Unified Profiles users to import common Salesforce objects:
8
8
-[Accounts](#accounts)
@@ -18,9 +18,9 @@ To selectively import columns, replace the `a*`, `c*`, or `l*` with a list of fi
18
18
19
19
To import Salesforce Accounts into Unified Profiles as Segment Unify profiles, create a RETL mapping with the following format.
20
20
21
-
Replace `<database_name.account_table>` with your database name and account table, `PHONE` with the name of the column in your warehouse that contains phone numbers, and `BILLING_COUNTRY` with the name of the column in your warehouse that contains the account's country. In this example query, the `PHONE` column is the primary contact phone number and what you import as the Profile’s 'phone' trait.
21
+
Replace `<database_name.account_table>` with your database name and account table, `PHONE` with the name of the column in your warehouse that contains phone numbers, and `BILLING_COUNTRY` with the name of the column in your warehouse that contains the account's country. In this sample query, the `PHONE` column is the primary contact phone number and what you import as the Profile’s 'phone' trait.
22
22
23
-
The other phone fields for Salesforce Accounts are PersonHomePhone, PersonMobilePhone, & PersonOtherPhone, and could be substituted for `PHONE` in this query. **You can only import one phone number field as the identifier used for lookups in Flex.**
23
+
The other phone fields for Salesforce Accounts are PersonHomePhone, PersonMobilePhone, & PersonOtherPhone, and could be substituted for `PHONE` in this query. **You can only import one phone number field as the identifier used for lookups in Unified Profiles.**
24
24
25
25
```sql
26
26
SELECT
@@ -48,7 +48,9 @@ To import Salesforce Contacts into Unified Profiles as Segment Unify profiles, c
48
48
49
49
Replace `<database_name.contact_table>` with your database name and account table, `PHONE` with the name of the column in your warehouse that contains phone numbers, and `BILLING_COUNTRY` with the name of the column in your warehouse that contains the contact's country.
50
50
51
-
Salesforce objects have several phone number-related fields. In this example query, the `PHONE` column is the primary contact phone number and what you import as the Profile’s 'phone' trait. The other phone fields for Salesforce Contacts are HomePhone, MobilePhone, & OtherPhone, and could be substituted for `PHONE` in this query. **You can only import one phone number field as the identifier used for lookups in Flex.**
51
+
Salesforce objects have several phone number-related fields. In this sample query, the `PHONE` column is the primary contact phone number and what you import as the Profile’s 'phone' trait.
52
+
53
+
The other phone fields for Salesforce Contacts are HomePhone, MobilePhone, & OtherPhone, and could be substituted for `PHONE` in this query. **You can only import one phone number field as the identifier used for lookups in Unified Profiles.**
52
54
53
55
```sql
54
56
SELECT
@@ -75,7 +77,9 @@ To import Salesforce Leads into Unified Profiles as Segment Unify profiles, crea
75
77
76
78
Replace `<database_name.lead_table>` with your database name and lead table, `PHONE` with the name of the column in your warehouse that contains phone numbers, and `BILLING_COUNTRY` with the name of the column in your warehouse that contains the lead's country.
77
79
78
-
Salesforce objects have several phone number-related fields. In this example query, the `PHONE` column is the primary contact phone number and what you import as the Profile’s 'phone' trait. The other phone fields for Salesforce Leads are HomePhone, MobilePhone, & OtherPhone, and could be substituted for `PHONE` in this query. **You can only import one phone number field as the identifier used for lookups in Flex.**
80
+
Salesforce objects have several phone number-related fields. In this sample query, the `PHONE` column is the primary contact phone number and what you import as the Profile’s 'phone' trait.
81
+
82
+
The other phone fields for Salesforce Leads are HomePhone, MobilePhone, & OtherPhone, and could be substituted for `PHONE` in this query. **You can only import one phone number field as the identifier used for lookups in Unified Profiles.**
0 commit comments