Skip to main content
Question

A developer configures a Record Type with Data Sync enabled and adds a record relationship to a secondary entity. After deploying, they notice that changes made directly in the database to the related entity are not reflected in the record list until several minutes later, and sometimes not at all after a manual refresh. What behavior explains this, and how should they handle near-real-time data requirements?

A
Anonymous
July 11, 2026

Answer

Synced record data can look stale because Appian Data Sync does not continuously monitor the underlying database. With Data Sync on, Appian uses optimized data access: it stores a synchronized copy of the source data in its internal data service, and queries against synced record types read that copy instead of the database. Changes made directly to the database by external applications, SQL scripts, or other systems may not show up in Appian right away.


1. Root cause

Take a telecom support application with two record types. The Customer record type stores customer ID, name, and phone number. The Support Ticket record type stores support tickets and has a relationship with Customer.


A customer updates their phone number in an external CRM, and the CRM writes to the Customer table directly. Appian does not detect every external database update, so the Customer record type still holds the previously synced data. The Support Ticket record type reads related customer information from that outdated data. When an agent opens the Support Ticket record list, the old phone number shows until the relevant data syncs.


A relationship does not sync changes to the related record type. Each synced record type follows its own sync behavior.


2. Interface refresh vs. data sync

Refreshing an interface does not fetch the latest data from the database. A refresh re-runs the interface’s query against the record data Appian already holds. A data sync pulls updated information from the source and updates that data.


For example, a!refreshVariable() with refreshOnVarChange refreshes the interface but does not trigger a record type sync. If the synced data is outdated, the interface keeps showing old values after a refresh.


3. Solutions for near-real-time requirements

Solution 1: Write Records smart service. If Appian manages the data changes, use Write Records. For supported synced, database-backed record types, Appian syncs the changes made through this smart service automatically. It is the preferred approach when data is updated through Appian interfaces or process models.


Solution 2: Sync Records smart service. When an external system updates the database, use the Sync Records smart service or a!syncRecords() to sync the affected records. For example:

  1. An external CRM updates Customer ID 1001.
  2. The CRM sends a webhook notification to an Appian web API.
  3. Appian triggers Sync Records for Customer ID 1001.
  4. Appian retrieves the latest customer information from the database.
  5. The updated information is available to record queries once the sync completes.

This gives near-real-time updates without repeatedly syncing the whole table. Sync Records supports up to 1,000 record identifiers per request.


Solution 3: Scheduled incremental sync. If an external system updates database records often, schedule incremental syncs. Appian uses a Last Modified field to find records changed since the previous successful sync. If a CRM updates hundreds of customer records during the day, Appian can sync the changed ones every few minutes, depending on the schedule.

  1. Scheduled incremental sync is available in the Advanced and Premium capability tiers.
  2. For database-backed record types, it supports tables, not views.
  3. It does not detect hard-deleted records, so you may also need a full sync.


Solution 4: Direct data access. If the business needs immediate visibility of database changes and syncing can’t meet that, use a non-synced record type with direct data access. Appian then queries the database itself instead of relying on synced data. Query performance depends on database performance, indexing, and query complexity. Modern Appian versions also support relationships for eligible non-synced record types when the related features are enabled.


4. Troubleshooting stale records

If updated data still doesn’t appear, check the following:

  1. Sync history: confirm the sync completed successfully for the affected record type.
  2. Related record type: confirm the related Customer record type has also synced its changes.
  3. Last Modified field: confirm external database updates maintain the timestamp that incremental sync relies on.
  4. Sync errors: review failed or skipped syncs. A skipped sync can leave older synced data available but outdated.
  5. Manual sync: trigger a sync of the affected record type and confirm the latest database values come through.


Appian Documentation

  1. Data Access for Record Types
  2. Configure Sync Options
  3. Sync Records Smart Service

Check yourself

Question 1 of 5, on what the answer above covers.

  1. 1.
    An external CRM updates a customer's phone number directly in the database. A support agent opens the Appian record list and still sees the old number. What is the most likely cause?
JuniorRecords#records