Forum Discussion
Krish_76
9 years agoFrequent Visitor
Leading Zero Issue
Hello everyone I am having trouble with the Zip codes when it has 0 as the leading. Example : I have data like this in excel NJ 07306 TN 38120 When i imported into Power BI, it is ...
- Anonymous9 years ago
Quick solution is to create a new custom column in DAX with a formula:
FullZip = FORMAT([Zip], "00000")
Where [Zip] is your zip code field name.
Anonymous
9 years agoNot applicable
Quick solution is to create a new custom column in DAX with a formula:
FullZip = FORMAT([Zip], "00000")
Where [Zip] is your zip code field name.
- d-mo8 years agoRegular Visitor
I am getting an Expression.Error: The name 'FORMAT' wasn't recognixed. Make sure it's spelled correctly.
- ACT8 years agoFrequent Visitor
I am too...I tried to write it within the Advanced Query Editor rather than creating a new column as well...tried to edit format changes, etc. Can't seem to get it to work. =(
- Ashish_Mathur8 years agoSuper User
Hi,
The solution offered by Ross is a DAX one (not an M one). If you wish to solve this problem in Power Query, please read here.
Hope this helps.
- Krish_769 years agoFrequent Visitor
Thank you so much Ross