Forum Discussion
Detect type of column in Power Query Formula Language
This should be an idea, as the current implementation requires you to specify the column names. Adding a new column to a table means you need to update the "Change data type" step manually. There should be a "detect data type on all columns, exluding some" step so even automatically added columns will automatically get an auto-detected data type.
Alternatively, you could think about unpivoting your data so you sort the data according to data types. One column for quantitative values, one column for text values, and one column for the "Attribute" name. Then it's only a matter of adding rows to the table, rather than adding columns.
- thakks9 years agoHelper I
sminonese jPinhao were you guys able to work this out. Same issue i have come across where i have to detect the data type of new columns and convert accordingly.
- MarcelBeug9 years agoCommunity Champion
You can select the applicable columns and choose "Detect Data Type" on the Transform tab.
- thakks8 years agoHelper I
I have to detect dynamically, when new columns are picked up while importing the csv file. I wish if it was that simple.