When working with data, often the users want to assign multiple columns with a specific data type. It is possible in Alteryx to change data types of selected columns in bulk with just a few clicks.
Changing Data Type in Bulk using Alteryx:
Usually in Alteryx, users would have a select tool and change the data type for a column by selecting the column. When handling multiple columns, this approach to change data type for “one column at a time” would be very inefficient, especially in case of large data sets.
There is a way to assign data types to multiple columns in bulk. Let us consider a dataset whose multiple columns need to be modified. By connecting to the dataset and adding the select tool we can see the list of columns as shown below.
All the data fields have the same data type, if we wanted to change, let’s say, all the columns containing “Results” to be double data type, and all the columns containing “Attain” to be date time data type. Click on the first field containing “RESULT” and while holding the “Shift” key click on the last field containing “RESULT” to select the columns as shown below. Alternatively multiple fields can be selected by holding the “Ctrl” key and clicking on the individual fields one after the other.
Now click on the “Options” button and hover over the “Change Field Type of Highlighted Fields” and click on the desired data type as shown below.
Similarly, select the fields containing “ATTAIN”, and modify the data type from options menu as shown below.
Finally the modified data set is ready for further analysis as shown below.
By using the options from Select tool, it is easily possible to change data types of multiple columns in just a few clicks.