SQL-Query: Select Max(...) in an INSERT Statement
Posted on 2003-11-20
I wonder if there is any possiblity to do a query like that:
INSERT INTO Work_Orders (Order_No, User_ID, Correction_Level) VALUES(1,1,(SELECT MAX(Correction_Level) FROM T_Tool_Work_Orders WHERE Order_No=1)+1)
If I execute this in MS Access 2000 I get: "Reserved error (-3025); there is no message for this error."
I know how to solve that using 2 queries, but I wondered, if I could combine them...
Thanks for your help