Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    Regular Coder
    Join Date
    Jul 2005
    Posts
    131
    Thanks
    21
    Thanked 0 Times in 0 Posts

    MySQL - retreiving last 'row' added - n/m solved

    Hi,

    I've had this before, gone through post history and a few sites ive built where i might have used this and cant find it.

    Say ive just added a new peice of information to my table, i know theres a simple way of requesting that peice of info so i can get its auto-incremental ID number given to that row. That way i can then take that ID and pass it onto another table without having to search for the information i've just submitted.

    Thx,
    PaulC2K
    Last edited by PaulC2K; 05-30-2007 at 02:21 AM.

  • #2
    Regular Coder
    Join Date
    Jul 2005
    Posts
    131
    Thanks
    21
    Thanked 0 Times in 0 Posts
    nevermind, what a n00b, couple of minutes later and i spot what im looking for on the previous from where i was looking!

    mysql_insert_id();



  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •