# Data Tables
Data Tables are one of the ingestion approaches provided by the system in addition to the SDK Ingestion. Clients may import proprietary data into data tables for analysis.
Data Tables can be used as dimension tables for event and user properties and can be updated by importing form files.
# Create a Data Table
A new data table can be created by importing a form file (see How to Save CSV Files). Please note that the file in the Excel format should not exceed 100M and the file in the CSV format should not exceed 500M. If a data file exceeds the above sizes, it can be imported multiple times through incremental update.
The column name of the newly created data file should be consistent with the column name (top row) of the file to be uploaded, and the user should also designate the data type of each column. Please note that the data type of the primary key of a table cannot be changed after the table is created. The data type of the primary key affects the range of properties associated, as shown in the following table:
Data types of properties | Descriptions on adding dimension tables |
---|---|
Text, numbers, boolean | Dimension tables can be added, and the data type of the primary key should be the same as the property. |
Time | Dimension tables can be added, and the data type of the primary key should be text and time format should be designated as well. |
List | Dimension tables can be added, and the data type of the primary key data should be text. |
Row, array row | Dimension properties cannot be added. Dimension tables can be added to sub-properties of row. |
Whether data in each column is parsed properly can be confirmed on the preview interface. For data rows involving parsing failures, error details can be downloaded to obtain.
Data in a form file can be automatically inserted into the newly created table. If the values of the data in the first columns of different rows in the file are the same, then deduplication will be performed automatically. It will keep the data from the row with the smallest row number among the identical values before the data is inserted into the table. (Tips: The first column of the primary key of the table is uploaded by default. The value of the primary key cannot be repeated, so it will be automatically deduplicated)
# Update Data
The Incremental Update is a relatively lightweight updating approach that only needs to import a small amount of data that has changed when updating. If the primary key value of the imported data already exists in the data form, then an update will be performed. If not, the new value will be inserted into the primary key. Such an update approach does not affect primary key value that has not appeared in the imported table file.
Given the limitations on the size of the file to be uploaded each time (the size of an excel file should not exceed 100M while that of a CSV file should not exceed 500M), large volumes of data can be updated through multiple importations.
The schema of the table uploaded via incremental update needs to be exactly the same as that of the current Data Table (consistency requirements involve column name and column sequence).
In the case of a large scope of data changes or deletion of part of data, Replacement Update is recommended. Such an update approach first clears the data of the original table and then fully writes the data to be imported into the table. The requirements on the form file are the same as the incremental update.
Users may also update a data table via Data Table API. If the dimension table is created using an earlier version than v3.8, then data can be updated through Dimension table API.
# Managing Data Tables
In the module of Data Tables, management operations such as structural update, deletion of the tables, or version restoration of tables and data, can be performed.
The display name of the tables can be modified during the process of incremental update. Adding or deleting a column, or changing the data type of a column (changing the data type of the primary key field is not supported) can be fulfilled by replacement update.
Changes in table schema affect assets that have used such a table and won't take effect until they are released. Unpublished updates of a data table will also be notified on the publication status bar. The table schema and related influences should be reconfirmed prior to publication.
After changes in the data or schema of Data Tables, you can roll back to earlier versions within the Data Table Versions. It should be noted that what can be restored is the Data Table schema and the data within the table, excluding the association relationship between the Data Tables and properties.
Data Tables can not be recovered after deletion. If a Data Table has been added as a dimension table, then deleting the Data Table will also cause the deletion of the dimension table property created thereby.
Users can also manage a Data Table via Data Table API.
# Using Data Tables
In the module of Data Tables, you can directly add the Data tables as dimension tables for multiple properties. For details, see Configure Asscociated Properties. In addition, users can also add a data table as a dimension table within the module of user properties and event properties.
# Usage permissions
Category | Specific content | Company root | Administrator | Analyst | Member |
---|---|---|---|---|---|
Metadata viewing | Data Table preview, exporting dimension tables of properties, downloading Data Table content, downloading history of Data Table | ● | ● | ▲ | ○ |
Metadata editing | Adding new Data Table, editing Data Table, restoring a historical version of the Data Table | ● | ● | ▲ | ○ |
Description of permissions:
● Compulsory availability for roles
▲ Availability by default for roles, but unavailability is allowed
△ Unavailability for roles by default, but availability is allowed
○ Compulsory unavailability for roles