Question
Passing mysql values to create 2 records at once(HELP!!!)
hey lads, need some serious help from you. Lets say i've got
2 databases: orders and order_samples. User is logged in. He wants
to put an order. Fills up the form and press submit. My intentions
are to create two records at the same time but in a bit more
complex way:
when user creates new order (order table) he gets unique order ID (auto increment). But I want to create new record in order_samples table, which would have that new order ID in one of the columns. And I want to do that without any user interaction at the same time new order is being created. I hope that makes sense.
I been thinking I could create new order record, then scan database to return me the newest order ID made by particular user. But how to create second record (in order_samples table) on the same page automaticaly? any thought on that?
when user creates new order (order table) he gets unique order ID (auto increment). But I want to create new record in order_samples table, which would have that new order ID in one of the columns. And I want to do that without any user interaction at the same time new order is being created. I hope that makes sense.
I been thinking I could create new order record, then scan database to return me the newest order ID made by particular user. But how to create second record (in order_samples table) on the same page automaticaly? any thought on that?
