Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
2 years ago
Solved

Number.ToText not working as expected

Hi all,  trying to add leading Zeros in front of my live query in an extra column. The result must always 8 digits long including the leading zeros I tried: Number.ToText ( [Number], "0000000")) ...
  • slorin's avatar
    2 years ago

    Hi,

     

    Text.End("00000000" & Text.From([Number]),8)

     

    Text.Repeat("0", 8-Text.Length(Text.From([Number]))) & Text.From([Number])

    Stéphane