Let's say I have an int with the value of 1. How can I convert that int to a zero padded string, such as 00000001?
00000001
Declare @MyInt integer Set @MyInt = 123 Declare @StrLen TinyInt Set @StrLen = 8 Select Replace(Str(@MyInt, @StrLen), ' ' , '0')
2.1m questions
2.1m answers
60 comments
57.0k users