Data Import for App Users
2 minutes to readData import through a form lets your app users load data into your tables themselves, without an account user running an import for them. An app user attaches a file, submits the form, and the records land in the table.
It fits any situation where your app users hold the data, for example a supplier sending a price list or a coordinator uploading a weekly roster. Unlike a scheduled import, which collects a file from a repository site on a timetable, this import runs the moment someone submits the form.
Before you begin
- A plan that includes data import/export tasks
- A sample file that matches what your app users will upload, used to map fields
- A Submission Form DataPart with an attachment field
Create a data import task
The task is what turns an uploaded file into records. It holds the destination table and the mapping between the columns in the file and the fields in the table. You upload a sample file while creating it, so Caspio can build that mapping.
- In the top navigation, select Tools, then select Data import/export tasks.
- Select New Task, then select Import.
- Under Source, select the DataPart source type.
- Upload your sample file. Caspio reads its structure to build the field mapping.
- Under Import settings, select the destination table and the import type.
- Under Field configuration, map the columns in the file to fields in the table.
- Enter a name for the task and select Save.
Turn on data import for a Submission Form
- In the left navigation, select Designer.
- Select the AppPage that holds your Submission Form, then select the form.
- Edit the Submission Form DataPart and select the attachment field to open its settings.
- Select Data import.
- Select your import task from the list. Only tasks with the DataPart source type appear.
- Save the DataPart, then deploy the AppPage.
Supported file formats
App users can upload CSV, Excel, or XML files, or a ZIP archive containing files in those formats.
Review runs in History Logs
Each run appears in the task’s History Logs with the name of the uploaded file, plus the email address and directory name of the app user who uploaded it, so you can trace any imported record back to the person who submitted it.