Jump to content

Archived

This topic is now archived and is closed to further replies.

crouchjay

Can I insert and select

Recommended Posts

I want to create a new row of data, but I need the query to return the newly created rowID. How do I go about doing this?


Jay,

Share this post


Link to post
Share on other sites
on the php side, use mysql_insert_id().

within mysql, use SELECT LAST_INSERT_ID()

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.