Creates a DataTable according to a specified schema.
Clicking the DataTable button in the activity body opens the Build Data Table window, which enables you to customize the table to be created.
By default, two columns and two rows are displayed. The first row contains some values that can be edited. The second row cannot be removed, but it is not displayed in the output table.
Clicking the Add Column button opens the New Column window. It helps you create and customize each new column you want to add to the data table. After creating a new column, you can edit its properties by clicking the Edit Column button.
Changing the data type of a column erases all data in that column.
It contains the following fields:
- Column Name - The title of the column. This field supports only strings.
- Data Type - The type of values that the new column is going to accept.
- Allow Null - If this check box is selected, null values can be added to the rows of this column.
- Auto Increment - The check box is displayed only if the Data Type is set to Int32. If selected, the value of this column is automatically incremented by 1 every time a new row is added.
- Default Value - The default value of all the rows that are to be added to this column.
- Unique - If selected, all the rows in this column need to have unique values.
- MaxLength - The maximum number of characters accepted for this column. If you do not want to enforce a maximum length, the default value is -1.
- DataTable - A DataTable variable that stores the information added in the Build Data Table window.
- DisplayName - The display name of the activity.
- Private - If selected, the values of variables and arguments are no longer logged at Verbose level.
You can see how the Build Data Table activity is used in an example that incorporates multiple activities and it is used for managing multiple databases. You can check and download the example from here.
Updated 21 days ago