On Sun, 7 Apr 2002 19:56:47 -0500
Paul DuBois <[EMAIL PROTECTED]> wrote:

> >I am running MySQL 3.23.41-17 on a stock SuSE 7.3 install.  I have a table
> >"customers" with an auto-incrementing primary key "customer_id".  If I insert
> >a record:
> >mysql> insert into customers(customer_id) values ("10");
> >and then ask for the last insert:
> >mysql> select last_insert_id();
> >(which I thought was the correct syntax) I get the response "0".
> 
> You're inserting a specific value into the AUTO_INCREMENT field, which
> doesn't result in the creation of a new automatic sequence number.

why don't just use "insert into customers(customer_id) values ("");" ???

-- 
Let's call it an accidental feature.
        -- Larry Wall

---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to