SELECT RIGHT('000000' + CAST([ID] as SYSNAME), 8) ID
FROM Table1
The above query makes a column right justified and left zero filled in sql server.
Can Some one let me know the equivalent in Oracle DB?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
SELECT LPAD(ID,8,'0') FROM Table1may work for you.Look at this for lpad usage