Re: Inserting data into related tables
If you're inserting user and order at the same time, insert the user first, query last_insert_id() to find the id that was generated, then populate orders.user_id with that value when inserting the order.
Edited 1 time(s). Last edit at 09/07/2022 01:18PM by Peter Brawley.
Subject
Written By
Posted
September 06, 2022 11:02PM
September 07, 2022 05:03AM
September 07, 2022 11:13AM
Re: Inserting data into related tables
September 07, 2022 11:22AM
Sorry, only registered users may post in this forum.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.