How can I add leading zeros in Power Query only if a certain criteria is met. For example, I have a column where the number of digits can range from 10-13, but all of them need to be 13 digits. So if the field contains 10 digits, I would need to add 3 leading zeros. If it contained 11 digits, I would need to add 2 leading zeros, etc.
Solved! Go to Solution.
If you need to keep them as number format, you can also use Custom Format Strings after you load the data.
We are excited to announce the Power BI Super Users!
Join digitally, March 2–4, 2021 to explore new tech that's ready to implement. Experience the keynote in mixed reality through AltspaceVR!
100+ sessions, 100+ speakers, Product managers, MVPs, and experts. All about Power BI. Attend online or watch the recordings.