To set up a database in an application, you have three options:
- create a blank database that starts without any records in the Build page, or
- create a blank database from within a Write to a Database action, or
- upload a Microsoft Excel file (.xlsx), and convert it into a database to start with the records in the Excel file.
Existing databases can be edited. You can add new database fields, however, you cannot delete existing fields or change their field types.
Set up a blank database
You have the option to create an empty database—devoid of any records—either on the Build page of your application or directly within the module editor while adding a Write to a Database action.
Create blank database on the Build page of application
-
In your application, click + New, then, select New database to add a new database to the application.
-
Provide a name for your database. The name is restricted to 50 characters but can contain uppercase letters, blank spaces, or emojis. After providing the name, click Create.
-
Determine the database fields and field types. Field names can contain blank spaces and uppercase letters. You can add up to 300 database fields.
-
If you would like, you may rename the Special fields Unique identifier, Case creation date and Last update. For example, when you use email addresses as unique identifiers, rename the Unique identifier field to Email address.
-
Once you have added all fields, select Save configuration.
To interrupt setting up the database, click Set up later. However, be aware that only the name of the database will be saved; your drafted configurations will be lost.
Create blank database in a Write to a Database action
Additionally, you have the option to create a new database within a Write to a Database action as you build your module in the editor.
- Click on + Configure new database, provide a name for the database, and define its fields.
Note that any restrictions from the previous paragraph apply. - Complete the database creation process by clicking Create new database.
Set up a database from an Excel sheet
-
In your application, click + New and select New database to add a new database to the application.
-
Provide a name for your database. The name is restricted to 50 characters but can contain uppercase letters, blank spaces, or emojis.
-
Upload an .XLSX file. See below for exact requirements.
-
Your file is scanned and the appropriate database configuration is automatically suggested: Field names are derived from the header in your Excel sheet. The correct field type is suggested, but can be changed.
-
The first column will be interpreted as unique identifier and its name will be taken over. If you would like, you may rename the Special fields Case creation data and Last update.
-
Check in the Preview database page to confirm whether the entries of your Excel table have been interpreted correctly. If not, change the Excel table and click Reupload Excel file. Otherwise, click Publish database to create your database.
The data uploaded from your Excel file will be available in all environments. If you want to upload data into one environment only, use the data management features. There, you can also update a database's content by uploading a new .CSV file.
Requirements for Excel files
The Excel file you upload must comply with the following requirements in order to create a database:
-
The filetype Excel Workbook (.XLSX) is required.
-
The file must contain a header row with the names of the columns. These names will be used to name the fields of the database.
-
The values of the first column must be unique and must not contain duplicates, as the first row will be interpreted as unique identifier for your records.
The values of the first column must be unique and must not contain duplicates, as the first row will be interpreted as unique identifier for your records.
Edit database
Once you have created a database, you can edit its fields either within the database itself or using the Write to a Database action in your module.
Editing is applicable to both blank databases and those set up from Excel sheets.
To edit a database, navigate to its name in the Databases list, click on the respective row (for example, on the icon next to the name), and then click Edit database fields.
You can add more fields to your database. However, for consistency, you cannot remove existing fields or change the types.
Alternatively, in a Write to a Database action, click on the Edit database icon next to the selected database. Confirm your changes with the Update database button.
Related topics
- Learn more on databases in the introduction article.
- Write to databases with a Write to a Database action.
- Use your database record in a module with a Read From a Database action. Read single records, or read many records into a collection.
- Delete a database record with a Delete From a Database action.
- Display the records in your database to end users with a data view. Filter the records you display or equip them with Data view actions.