Re: [PHP] Questions regarding inserting and updating data into aMySQL db

2002-09-11 Thread Marek Kilimajer
mysql_insert_id() will tell you the number of last auto_increment insert, you can use this, but you must keep it using session on the server side for security reasons. But better solution be to use session or hidden fields in your forms to pass the values from page to page and insert them at o

Re: [PHP] Questions regarding inserting and updating data into aMySQL db

2002-09-10 Thread Chris Shiflett
You should search for some SQL tutorials on the Web. What it sounds like you are looking for is the "update" SQL statement which modifies an existing row (for your second form, for example). Thus, you "insert" the row to create it (which assigns the key using the auto increment), then "update"