MySQL move record from one table to another
Posted: Tue Sep 06, 2005 3:55 am
Hi Guys
I have the ID of the record i want to move from one table to the other but I do not know how to transfer it. There must be a simple way other that selecting everything from the first table, making them into variables, inserting into the second then deleting the first.
I've had a look at SELECT * INTO $helpdesk_submission FROM $helpdesk WHERE id='$id' but this does not seem to work, or is not compatable with MySQL.
I'm using MySQL 4.0.20
Thanks for any ideas you may have
I have the ID of the record i want to move from one table to the other but I do not know how to transfer it. There must be a simple way other that selecting everything from the first table, making them into variables, inserting into the second then deleting the first.
I've had a look at SELECT * INTO $helpdesk_submission FROM $helpdesk WHERE id='$id' but this does not seem to work, or is not compatable with MySQL.
I'm using MySQL 4.0.20
Thanks for any ideas you may have