---
title: "How data import works"
site: admin
version: 2027.1
versions: "all"
url: https://docs-new.servicely.ai/admin/2027.1/data-import/how-data-import-works/
type: concept
application: platform
last_updated: 2026-12-03
commit: 8d233372fa05
---


Data import is the platform mechanism that loads records from outside Servicely into its tables. It is for administrators who load spreadsheets, directory data or integration feeds, and need to know where to look when an import goes wrong.

## The three stages

Every import runs in three stages. You can run them one at a time or together.

| Stage | What happens | Where it is recorded |
| --- | --- | --- |
| Import | Servicely reads the data from an import source and writes one staging record per source row. | **Previous imports** (import logs) |
| Transform | A transform map says how each staging field becomes a field on the target table. | The transform map and its field mappings |
| Load | Servicely runs the transform map over the pending staging records and creates or updates target records. | **Previous loads** (import loads) |

All of this lives under the **Data import** menu, in the **Import**, **Transform** and **Load** sections. The **Servers** section holds the SOAP, LDAP and JDBC server records that some sources connect to.

## Import sources

An import source says where the data comes from. Its **Type** is one of Attachment, File, Inbound, JDBC, LDAP, REST or SOAP. A spreadsheet or CSV file is an Attachment source. For CSV and XLS sources you can set the header row and, for XLS, the sheet. Both default to 1.

<Callout type="info">
  **Changed in 2027.1.** A REST import source cannot reach loopback, link-local, cloud metadata or private network addresses, or the instance itself. Servicely checks every redirect too.
</Callout>

You can create the source in advance, or let the **Import data** page create it from an uploaded file. To import an updated file later, replace the attachment on the existing source and import into the existing staging table. That keeps one source and one staging table per feed.

## Staging tables

A staging table holds the imported rows before they reach the target. Servicely generates it from the columns in the source, so you never add its fields yourself. Each row becomes one record, with a state of Pending, Success or Error and a link to the target record once loaded. Open them from **Data import → Import → Import staging tables**.

<Image src="asset:screenshots/admin/data-import-how-data-import-works/import-menu.png">The Import section of the Data import menu with Import staging tables.</Image>

The staging table keeps every row from every import, so the same row can appear more than once. Check it first when data does not arrive as you expect: it shows what was imported, its state and the record it updated. After a staging table is generated, refresh the browser if its field labels do not show.

| Operation | What it does |
| --- | --- |
| **View records** | Lists the staging records with their data, state and target. |
| **Generate temporary table** | Creates the staging table. An import does this for you. |
| **Delete temporary table** | Deletes the staging table and its records. Target records are not affected. |
| **Reset state** | Sets every record from every import back to pending, so the next load processes them all again. Use it only when the table holds a single import. |
| **Delete records** | Deletes the staging records. Target records are not affected. |

## Transform maps and loads

A transform map names a source table, which is the staging table, and a target table. Its field mappings copy, look up or calculate each target field, and its scripts run before and after each row. The fields, mapping types and script variables are in [Transform maps](page:data-import/transform-maps).

A load runs one transform map with an import load type:

<!-- source: platform/data/AvailableValue?Table=ImportLoad&Field=Type -->
| Load type | Effect on the target table |
| --- | --- |
| Create | Creates a record for each row. A row that matches an existing record is ignored. |
| Update | Updates the matching record. A row with no match creates a record, as Sync does. |
| Delete | Deletes the matching record. A row with no match is ignored. |
| Sync | Updates the matching record, or creates one when there is no match. This is the default. |

Rows match target records by the field mappings marked **Primary key**. A load needs at least one, and a row whose primary key value is empty fails with an error.

## Housekeeping

Staging tables, import logs and import loads grow with every run. Servicely ships system table cleanup records that delete import logs and import loads after seven days. Add a cleanup record for each staging table you keep, as described in [System table cleanup records](page:platform/jobs-and-logs/system-table-cleanup-records).

## Related

- [Import a spreadsheet](page:data-import/import-a-spreadsheet)
- [Transform maps](page:data-import/transform-maps)
- [Schedule imports](page:data-import/schedule-imports)
- [System table cleanup records](page:platform/jobs-and-logs/system-table-cleanup-records)
