Click here to Skip to main content
15,881,559 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
\>I want to increment id value but its datatype is varchar.The id contain some prefix as alphabet
e.g TYCS001
Posted
Comments
ZurdoDev 20-Mar-13 9:13am    
Strip the prefix and then increment the number portion and add them back together. Where are you stuck?

1 solution

Look into composite keys. The numer portion of your key can be an autoincremented column.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900