external data integration: easy & efficient with upsert and external ids

27
Salesforce Data Integration Techniques @DouglasCAyers douglascayers.co m Doug Ayers Salesforce MVP Senior Developer, GearsCRM The Power of Upsert & External IDs https://www.youtube.com/playlist?list=PL-oxrNbxQl3_u90rcINl DZAfUo4f8-bUP

Upload: doug-ayers

Post on 16-Apr-2017

384 views

Category:

Technology


5 download

TRANSCRIPT

Page 1: External Data Integration: Easy & Efficient with Upsert and External IDs

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

Page 2: External Data Integration: Easy & Efficient with Upsert and External IDs

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.

Page 3: External Data Integration: Easy & Efficient with Upsert and External IDs

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

Page 4: External Data Integration: Easy & Efficient with Upsert and External IDs

Gold Salesforce Partner SI & ISVOver 60 Salesforce professionals100% Work RemotelyCommunities, Service Cloud, Integrations

Page 5: External Data Integration: Easy & Efficient with Upsert and External IDs

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

Page 6: External Data Integration: Easy & Efficient with Upsert and External IDs

Not System of Record How to Prevent Duplicates? How to Link Records?

External Data Integration

ERP OMSEMR

Page 7: External Data Integration: Easy & Efficient with Upsert and External IDs

ExportRecords

VLOOKUP to Match

Insert Non-MatchesUpdate Matches

1

2

3

Traditional Approach

Page 8: External Data Integration: Easy & Efficient with Upsert and External IDs

ExportParentRecords

VLOOKUP to Match

1

2

ExportExistingRecords

VLOOKUP to Match

Insert orUpdate

3

4

5

Traditional Approach

Page 9: External Data Integration: Easy & Efficient with Upsert and External IDs

1

2

3

4

5

6

7

Traditional Approach

Page 10: External Data Integration: Easy & Efficient with Upsert and External IDs

How you feel juggling all the files…

Page 11: External Data Integration: Easy & Efficient with Upsert and External IDs

How you feelwhen it goes wrong…

Page 12: External Data Integration: Easy & Efficient with Upsert and External IDs

TediousError Prone

Doesn’t Scale

Traditional Approach

Page 13: External Data Integration: Easy & Efficient with Upsert and External IDs
Page 14: External Data Integration: Easy & Efficient with Upsert and External IDs

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

Page 15: External Data Integration: Easy & Efficient with Upsert and External IDs
Page 16: External Data Integration: Easy & Efficient with Upsert and External IDs

First, you need External IDs

Page 17: External Data Integration: Easy & Efficient with Upsert and 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

# @

Page 18: External Data Integration: Easy & Efficient with Upsert and 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

Page 20: External Data Integration: Easy & Efficient with Upsert and External IDs

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!

Page 21: External Data Integration: Easy & Efficient with Upsert and External IDs

Best Practices Mark External IDs as Unique

Use Compound Values for Uniqueness“Hospital-100Patient-123” “Hospital-200Patient-123”

Page 22: External Data Integration: Easy & Efficient with Upsert and External IDs

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

Page 23: External Data Integration: Easy & Efficient with Upsert and External IDs

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!

Page 24: External Data Integration: Easy & Efficient with Upsert and External IDs

ResourcesTwitter: @douglascayers Blog: douglascayers.com Code: github.com/douglascayers Video: youtube.com/c/douglascayers

Page 25: External Data Integration: Easy & Efficient with Upsert and External IDs

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

Page 26: External Data Integration: Easy & Efficient with Upsert and External IDs

Questions?

Page 27: External Data Integration: Easy & Efficient with Upsert and External IDs

Thank Y u