mysql Q
mysql Q
Out of context: Reply #7
- Started
- Last post
- 7 Responses
- neverblink0
if you have MySQL 4.1+ then you can also do this with a subquery
INSERT INTO 'table' ('id', 'content') VALUES (SELECT MAX(table.id)+1, 'foobar')
if you have MySQL 4.1+ then you can also do this with a subquery
INSERT INTO 'table' ('id', 'content') VALUES (SELECT MAX(table.id)+1, 'foobar')