Forum Discussion

Sheref_Morad's avatar
Sheref_Morad
Frequent Visitor
4 years ago
Solved

Date Column

I have a column in Power Query that has a several years period as a Whole Number, I want to transfer it to a date column  
  • Anonymous's avatar
    Anonymous
    4 years ago

    Hi Sheref_Morad ,

    First, change the data type of Year Column to Text.

    And now , again change the data type to Date, it'll work.

    #"Changed Type1" = Table.TransformColumnTypes(#"Replaced Value",{{"Year", type text}}),
        #"Changed Type2" = Table.TransformColumnTypes(#"Changed Type1",{{"Year", type date}})