I have received few emails asking how to prefix any number with zero. I have previously written two articles for the same subject. Please refer to my previous articles.
SQL SERVER – Pad Ride Side of Number with 0 – Fixed Width Number Display
SQL SERVER – UDF – Pad Ride Side of Number with 0 – Fixed Width Number Display
Let me know if you are aware of any other method.
Reference : Pinal Dave (https://blog.sqlauthority.com)