Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
5 years ago
Solved

Custom column how do i convert date (mm/dd/yyyy) to a serial number?

Good day is there a way to convert a column [date] (dd/mm/yyyy) to serial number in power query, just as the regular excel do when the column is formatted as general. I do need to get the serial number and concatenate it with [id number] because ill use it as a lookup value.

 

i need the output like the one on "WE+Entity ID" header

  • Anonymous's avatar
    Anonymous
    5 years ago

    If your last step or Table name is "Table1", then just make a new step, and in the formula bar, type:

     

    =Table.TransformColumns(Table1, {{"date", Number.From}})

     

    You can concatenate if you then change the date number to text.

     

    --Nate

2 Replies

  • Anonymous's avatar
    Anonymous
    Not applicable

    If your last step or Table name is "Table1", then just make a new step, and in the formula bar, type:

     

    =Table.TransformColumns(Table1, {{"date", Number.From}})

     

    You can concatenate if you then change the date number to text.

     

    --Nate

    • Anonymous's avatar
      Anonymous
      Not applicable

      Wow thanks i didn't know that it was that easy! Thanks for the help 🙂