mysql: auto_incremented field in two tables

From: Date: Sun, 18 Feb 2001 19:16:44 +0000
Subject: mysql: auto_incremented field in two tables
Groups: php.db 
Request: Send a blank email to php-db+get-6729@lists.php.net to get a copy of this message
Hi all, After I insert a row in table1, the value of the auto_incremented field should also be put in table2. How should I do this? I've tried putting 'mysql_insert_id()' after the insert-command but no success, it seems that this value restarts from 0 every new session... anyone? thanks, Juan :o)

« previous php.db (#6729) next »