external data integration: easy & efficient with upsert and external ids
TRANSCRIPT
Salesforce Data Integration Techniques
@DouglasCAyersdouglascayers.com
Doug Ayers Salesforce MVP
Senior Developer, GearsCRM
The Power ofUpsert & External IDs
https://www.youtube.com/playlist?list=PL-oxrNbxQl3_u90rcINlDZAfUo4f8-bUP
Forward-Looking StatementsStatement under the Private Securities Litigation Reform Act of 1995:
This presentation may contain forward-looking statements that involve risks, uncertainties, and assumptions. If any such uncertainties materialize or if any of the assumptions proves incorrect, the results of salesforce.com, inc. could differ materially from the results expressed or implied by the forward-looking statements we make. All statements other than statements of historical fact could be deemed forward-looking, including any projections of product or service availability, subscriber growth, earnings, revenues, or other financial items and any statements regarding strategies or plans of management for future operations, statements of belief, any statements concerning new, planned, or upgraded services or technology developments and customer contracts or use of our services.
The risks and uncertainties referred to above include – but are not limited to – risks associated with developing and delivering new functionality for our service, new products and services, our new business model, our past operating losses, possible fluctuations in our operating results and rate of growth, interruptions or delays in our Web hosting, breach of our security measures, the outcome of any litigation, risks associated with completed and any possible mergers and acquisitions, the immature market in which we operate, our relatively limited operating history, our ability to expand, retain, and motivate our employees and manage our growth, new releases of our service and successful customer deployment, our limited history reselling non-salesforce.com products, and utilization and selling to larger enterprise customers. Further information on potential factors that could affect the financial results of salesforce.com, inc. is included in our annual report on Form 10-K for the most recent fiscal year and in our quarterly report on Form 10-Q for the most recent fiscal quarter. These documents and others containing important disclosures are available on the SEC Filings section of the Investor Information section of our Web site.
Any unreleased services or features referenced in this or other presentations, press releases or public statements are not currently available and may not be delivered on time or at all. Customers who purchase our services should make the purchase decisions based upon features that are currently available. Salesforce.com, inc. assumes no obligation and does not intend to update these forward-looking statements.
1. Force.com Developer2. Platform App Builder3. Platform Developer 14. Platform Developer 2 (multiple-choice)5. Development Lifecycle & Deployment6. Identity & Access Management7. Sharing & Visibility Designer8. Mobile Solutions Architecture9. Integration Architecture Designer
Doug Ayers Salesforce MVP
Senior Developer, GearsCRM Nashville Developer Group Leader
douglascayers.com @DouglasCAyers
Gold Salesforce Partner SI & ISVOver 60 Salesforce professionals100% Work RemotelyCommunities, Service Cloud, Integrations
Agenda
What is External Data Integration? Traditional Approach Introduce Upsert and External IDs Demo Concept by Populating Sandbox Best Practices How this fits with Master Data Management Questions
1
2
3
4
5
6
7
Not System of Record How to Prevent Duplicates? How to Link Records?
External Data Integration
ERP OMSEMR
ExportRecords
VLOOKUP to Match
Insert Non-MatchesUpdate Matches
1
2
3
Traditional Approach
ExportParentRecords
VLOOKUP to Match
1
2
ExportExistingRecords
VLOOKUP to Match
Insert orUpdate
3
4
5
Traditional Approach
1
2
3
4
5
6
7
Traditional Approach
How you feel juggling all the files…
How you feelwhen it goes wrong…
TediousError Prone
Doesn’t Scale
Traditional Approach
Did he say “upsert”?? InsertAlways creates new records
UpdateMakes changes to records whose Salesforce ID you know
UpsertInserts or Updates based on existence of the recordMatches on External ID field to determine existence
First, you need External IDs
Supported Data Types Choose Record Identifiers New Super Powers
Customer Numbers Order Numbers
Searchable Indexed Improved Filter
Performance
Auto NumberNumberTextEmail
Setting Up External Ids
# @
Use Case: Populating Sandboxes
Create Salesforce Migration ID field in sandbox Unique, Case-Sensitive, External ID Export Data from Production Import Data to Sandbox Upsert matching on Salesforce Migration ID Map exported ID field to Salesforce Migration ID
1
2
3
Demo!https://www.youtube.com/watch?v=u1rkHv75YN8&index=2&list=PL-oxrNbxQl3_u90rcINlDZAfUo4f8-bUP
Upsert Benefits
Simplifies insert/update operations! Do not have to know Salesforce IDs! Do not have to export and match on
existing records! Helps prevent duplicates! Fewer API calls needed!
Can set lookup fields too!
Best Practices Mark External IDs as Unique
Use Compound Values for Uniqueness“Hospital-100Patient-123” “Hospital-200Patient-123”
Use Case: Multiple Source Systems
SystemA
SystemB
SystemC
Upsert asExternal ID
Master Record ID System A ID System B ID System C ID1001 A1 B10 C1111002 A2 B20 C222
Use Case: Multiple Source Systems
Benefits Mashups with Canvas apps Deep linking to related systems More context on layouts & reports
Map Other System IDs to Salesforce Too!
ResourcesTwitter: @douglascayers Blog: douglascayers.com Code: github.com/douglascayers Video: youtube.com/c/douglascayers
Further Reading My Blog Posts: Part 1 and Part 2 Blog posts by Jeff Douglas and Jitendra Zaa Data Import: Cleaning Up Your Import File Red Argyle: VLOOKUP Explained Salesforce University: Integrating with SOAP API Apex Developer Guide: Upserting Records Apex Developer Guide: Working with Large Data Volumes How do I use an External ID to import related records? Master Data Management Strategy for the Enterprise
Questions?
Thank Y u