By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,717 Members | 1,276 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,717 IT Pros & Developers. It's quick & easy.

replace number with string name

P: 1

how can I replace numbers from -1 to 15 with string in MSSQL? For e.g.:
-1 = TEST1
1 = TEST2
2 = TEST3
12 = TEST123
13 = TEST1234

Thank you!
Nov 29 '12 #1
Share this Question
Share on Google+
1 Reply

Expert Mod 15k+
P: 31,769
You give no explanation and your example makes it very unclear what is behind your thinking.

Nevertheless, a table of matching values (that match your logic whatever that may be) would work for you.
Nov 29 '12 #2

Post your reply

Sign in to post your reply or Sign up for a free account.