HOW DO YOU FIND OUT WHICH AUTO INCREMENT WAS ASSIGNED ON THE LAST INSERT?

Arun Singh

Total Post:310

Points:1550
Posted by  Arun Singh
MYSQL 
 1988  View(s)
Ratings:
Rate this:
  1. Arun Singh

    Post:310

    Points:1550
    How do you find out which auto increment was assigned on the last insert?

    SELECT LAST_INSERT_ID() will return the last value assigned by the auto_increment function. Note that you don’t have to specify the table name.

Answer

NEWSLETTER

Enter your email address here always to be updated. We promise not to spam!