Salesforce Salesforce Connect and External Data Sources
Most integration approaches copy data into Salesforce — you import records and store them in the org. But some scenarios require a different approach: what if the data is too large to copy, changes constantly, or is governed by regulations that prevent duplication? Salesforce Connect solves this by letting Salesforce display external data in real time without copying it into the org. Users see live data as if it were a native Salesforce record.
What Is Salesforce Connect?
Salesforce Connect is a feature that creates External Objects — Salesforce objects that read data directly from an external system at the moment a user opens the record. Nothing is stored in Salesforce. The data lives in the source system. Salesforce acts as a live window into that data.
The Glass Wall Analogy
TRADITIONAL INTEGRATION: External System → Copy data → Store in Salesforce org (Data is duplicated. Two sources of truth. Sync issues possible.) SALESFORCE CONNECT: Salesforce ────── glass wall ────── External System User looks through the glass and sees live data. Nothing is copied. One source of truth always.
When to Use Salesforce Connect
- The external dataset is too large to store in Salesforce (hundreds of millions of rows)
- Data changes in real time and must always show the current value
- Regulatory or compliance requirements prohibit copying data into a third-party system
- You need read access to external data but do not need to create reports or run automation on it
External Objects vs. Standard Objects
| Feature | Standard / Custom Object | External Object |
|---|---|---|
| Data stored in Salesforce | Yes | No — lives in external system |
| API name suffix | __c | __x |
| Works in reports | Yes | Limited |
| Triggers supported | Yes | No |
| Real-time data | No (depends on last sync) | Yes — always current |
| Relationships with Salesforce objects | Lookup, Master-Detail | External Lookup, Indirect Lookup |
Adapters: How Salesforce Connect Connects
Salesforce Connect uses Adapters to translate between Salesforce and external systems. Think of an adapter as a plug converter — it makes different sockets compatible. Salesforce provides three built-in adapters:
OData 4.0 Adapter (and OData 2.0)
OData (Open Data Protocol) is a standard REST-based protocol for exposing data from databases and applications. If your external system speaks OData — many enterprise systems do — connect it directly using the OData adapter. No custom code needed.
Salesforce Adapter (Cross-Org)
This adapter connects one Salesforce org to another. Teams in different business units on separate orgs can view each other's records without duplicating data. Useful for companies that run multiple Salesforce orgs after mergers or acquisitions.
Custom Adapter (Apex Connector Framework)
When your external system does not support OData, you write a Custom Adapter in Apex using the Apex Connector Framework. This gives you full control over how Salesforce fetches data from any HTTP-based API.
Setting Up an External Data Source
The setup process in Salesforce has three main steps:
- Step 1: Create an External Data Source — in Setup, go to Integrations → External Data Sources. Define the connection: URL, authentication method, and adapter type.
- Step 2: Validate and Sync — Salesforce connects to the external system and retrieves the available tables or endpoints. You select which tables to sync.
- Step 3: External Objects are created automatically — Salesforce creates External Objects matching the external tables. You can then add fields, create relationships, and add them to page layouts like any other object.
External Relationships
External Objects support special relationship types that do not exist for standard objects:
External Lookup
Links a Salesforce standard or custom object to an External Object. The relationship field uses the External Object's External ID field as the link. Example: An Account record in Salesforce links to an Order record in your ERP system — users see the related ERP orders directly on the Account page.
Indirect Lookup
Links an External Object to a Salesforce standard or custom object using a custom unique field on the Salesforce side. Useful when the external system uses a different identifier than Salesforce's record Id.
External Lookup to External Object
Links one External Object to another External Object from the same external data source — creating a relationship entirely within the external system that Salesforce surfaces together.
Salesforce Connect and OData: A Practical Example
SCENARIO: Retail company uses Salesforce for CRM
and a separate Oracle database for order history.
Orders change constantly. 10 million+ records.
SOLUTION:
1. Oracle system exposes orders via OData endpoint
2. Salesforce Connect → OData Adapter → connects to Oracle
3. Salesforce creates External Object: Order__x
4. Indirect Lookup added: Order__x links to Account via Customer_ID__c
5. Account page now shows a related list of live Oracle orders
RESULT:
Sales rep opens Account "Reliance Retail" →
Sees all 847 orders directly on the Account page →
Data is live from Oracle — no copy, no sync, always current
Limitations of Salesforce Connect
- External Objects are not included in standard reports — you cannot build a Summary report on external data
- SOQL against External Objects is limited — not all operators and functions are supported
- Apex Triggers cannot be written on External Objects
- Performance depends on the external system's response time — a slow external API makes Salesforce pages load slowly
- Salesforce Connect requires an add-on license — it is not included in the base Salesforce editions
Key Points
- Salesforce Connect displays external data live inside Salesforce without copying it — using External Objects (API name ending in __x).
- Three built-in adapters cover most scenarios: OData (standard protocol), Salesforce-to-Salesforce (cross-org), and Custom Apex (any HTTP API).
- Setup requires creating an External Data Source, syncing tables, and then configuring the resulting External Objects like any other Salesforce object.
- External Lookup and Indirect Lookup relate External Objects to standard Salesforce records.
- Use Salesforce Connect when data is too large to import, changes too frequently to sync, or cannot legally leave its source system.
