Forum Discussion
Jumper
2 years agoHelper I
Column format not pulling through correctly from Excel source
Hi. I've got a data column in an Excel file that is formatted to 000, as it is a detail that needs to be viewed as a three digit code. But when I pull the detail into Power BI, any leading zeros...
jolind1996
2 years agoResolver II
In Power BI, you can retain leading zeros by converting the column to text format. Use the FORMAT function or concatenate an empty string to the alpha-numeric codes. For instance, use a formula like =FORMAT([Column],"000") or =[Column]&"". This ensures that the three-digit format is maintained and leading zeros aren’t dropped when importing data from Excel. This should help your codes order as expected and maintain the necessary three-digit format. Remember, Power BI treats numbers without leading zeros as numerical data, hence the need for this conversion. I hope this helps! If you have any other questions, feel free to ask.
Best regards,
Johannes