Jump to content

Its a dumb question but i dont know the answer (mysql_insert_id)


derrick24

Recommended Posts

This is more of a concern of mine, and I'm not too sure of how to even ask this question.

 

I have at the start of my script a normal connect to the database connection that can be used though out the remainder of the script by various functions (so basically any function can simply pull the data it requires without having to connect every time)

 

Now my concern is that I need to use "mysql_insert_id", if I have multiple uses inserting records in the database using the same connection started at the top of the script. Is that going to cause a conflict.

 

ie: if        userA inserts record 1      and      userB insert record 2      at the same time.

 

will userA still get a return id of 1 and userB a return id of 2 and not both get a return of 2 for example?

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

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.