Change Field Properties

Feature Overview:

The Change Field Properties feature in Astera Data Warehouse Builder allows users to modify field datatypes of multiple fields at once.

This feature is essential for data professionals tasked with adjusting field datatype properties of an entity in a data model, such as data types, DB types, length, and scale. The Change Field Properties functionality ensures that users do not have to modify each field individually.

Use Case

For our use case, we have an entity called Customers in a data model, with the following field layout:

image-20230707090912564

The following changes need to be made to all string datatype fields:

  • Change the dB types from ‘NVARCHAR’ to ‘VARCHAR’, if their length is between ‘10’ & ‘1000’, and change the length of newly modified ‘VARCHAR’ fields to ‘300’
  • Change the dB types from ‘NVARCHAR’ to ‘CHAR’ if their length is less than ‘10’, and change the length of newly modified ‘CHAR’ fields to ‘6’
  • Change the dB types from ‘NVARCHAR’ to ‘NCHAR’ if their length is ‘10’, while the length should remain unchanged.

1. To make the aforementioned changes, right-click on the Customers entity header and select the Change Field Properties option from the context menu.

image-20230707091143086

2. The Change Field Properties window will open. In the Find section select the source fields’ properties (datatype, dbtype, length and scale) which you want to replace.

3. Next, in the Replace with section, select the required field properties which you want to replace the source fields’ properties with, as shown below:

image-20230707091242136

4. For the first change in dB Type mentioned above, the following changes must be made in the Change Field Properties window:

image-20230707091327109

5. Once done, Click OK to save the change and close the window.

6. For the next change, open the Change Field Properties window again, and make the following changes:

image-20230707091409552

7. Once again, Click OK to save the changes and close the window.

8. For the final required change, open the Change Field Properties window again, and make the following changes:

image-20230707091510487

Note: You can use the Scale and Scale Between options in the Find section in the same manner as the Length and Length Between options.

  1. Click OK to save the changes and close the window.
  2. Now, open the Customer Entity’s field layout. You will see that all required changes have been made successfully.

image-20230707091602815

Similarly, this can be done with other datatypes and dB types as well.