zeff
|
Posted: 09/14/2003, 11:48 PM |
|
how can i do this?
i want after save a data into table/database .. i want to retrieve the new created id for the table. note that, the new created id will be display on the same page because the return page is same page.
|
|
|
Si Cranmer
|
Posted: 09/15/2003, 1:27 AM |
|
You dont say what DB.
If MySql you use $newid=mysql_insert_id() & I would then suspect you would have to change the redirect and add this field into the parameters passed.
HTH
Si.
|
|
|
zeff
|
Posted: 09/15/2003, 1:42 AM |
|
sorry i forget to mention about db. it is sql server + asp
|
|
|
Si Cranmer
|
Posted: 09/15/2003, 5:01 AM |
|
I think it should still be the same just
newid = mysql_insert_id()
|
|
|
Tom
|
Posted: 09/20/2003, 8:04 AM |
|
Check out the tips/articles as many are written about getting these 'Auto-Increment' or 'Primary Key Values'.
|
|
|