Search code examples
worksheet-functionexcel-2016

Transform the contents of a column in Excel


I have a .csv file which consists of 7 columns: ID, Title, Media-Type, Published, Content, Source and Label.

The .csv file/dataset is as given here:

Dataset

Now, what I want to do is transform the values given the last column of "Label". That is, I want to convert the "0"s in the dataset to read as "FALSE" and the "1"s in the dataset to read as "TRUE". Simply put, I want "TRUE" in place of 1s and FALSE in place of 0s. Is there any way this can be done? Any kind of help is appreciated. Thanks a lot in advance.


Solution

  • Use Get & Transform to open the CSV file, then select the column, replace 1 with TRUE and 0 with FALSE and load the result into a worksheet. That way you will have no formulas in the sheet. With Get & Transform you can also repeat the query with one click if the underlying data source changes.