Adding Tables and Columns to a Schema
This section describes how to add Tables and Columns to a Schema from the New Schema window.
Adding a Table
Add a table to a schema using Add Table.
Specify a name for the table. This is used to refer to the table in the Privitar user interface.
Once the table is created:
The name of the table can be changed by clicking on the Edit icon in the list.
The table can be deleted by clicking on the Delete icon in the list.
Adding a Column
To add columns to a table, follow these steps:
Select the table in the list and click on Add Column. The Add Column dialog box is displayed.
Enter a name for the column in the Name field.
Select a data type for the column from the Data Type list box.
For more information about the data types that are supported by Privitar, see Privitar Data Types. Any data types that are not directly supported in Privitar can be classified as Other.
There are a few other considerations to be aware of when selecting the data types to be used:
Privitar strictly validates data types as per the Schema. If the defined Privitar Schema does not match the Schema of the input file, errors will occur during processing.
If the data type is a Date or a Timestamp, you will also have to add a CSV Date/Timestamp Format string to allow correct parsing of date strings. (For more information about Date and Timestamp formats supported by Privitar, see Date and Timestamp formats.) If the input file is not of CSV type (for example, an Avro or Parquet file), this setting will be ignored.
Select the Optional check box if you want the column to be optional. This means that this column is not present in all records that use this Schema.
Schemas containing optional fields can only be used in Data Flow Jobs and Privitar On Demand Jobs, not in Batch Jobs.
Click on Add to add the new column. If you have more columns to add, click on Add Another instead. This adds the new column, but keeps the Add Column dialog box open so that you can add more columns.
Click on Save to save the Schema.