|
Posted by Vincent THOREL on 10/13/73 11:17
Ashok wrote:
> Hi,
> I want to insert values in 2 tables from a form, but in the second table, I
> want to get the (new) id (auto_incr) of the first table in one of the column
> in 2nd table.
> Is it at all possible and how to do this if possible?
>
> Thanks.
> Ashok.
>
>
BEGIN TRANSACTION;
INSERT INTO table1 VALUES (...);
INSERT INTO5 table2 VALUES (LAST_INSERT_ID(), ...);
COMMIT;
Navigation:
[Reply to this message]
|