|
-
Aug 21st, 2006, 01:32 PM
#1
Thread Starter
Hyperactive Member
increment within update
how do you update a column in database and then increase the number by 1
like this
S.id Name
3 n
5 a
6 b
now i want to make an update statment that would make it become
S.id Name
1 n
2 a
3 b
i have
update tablename set columname = columname + 1;
but this only make it
S.id Name
4 n
6 a
7 b
plz help
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|