> I'm about to kill this terminal!  I'm using mysql 3.23.24-beta (my 
> host's choice, not mine).
> 
> I have a table...
> ====================================================================== 
> ===========
> mysql> describe users;
> +----------------+--------------+------+-----+---------+-------------- 
> --+----------------------+
> | Field          | Type         | Null | Key | Default | Extra 
> | Privileges           |
> +----------------+--------------+------+-----+---------+-------------- 
> --+----------------------+
> | uid            | int(11)      |      | PRI | NULL    | 
> auto_increment | select,insert,update |
> | name           | varchar(60)  |      |     |         | 

<cut>

> 
> I insert a first record...
> ====================================================================== 
> =========== mysql> INSERT INTO users VALUES ( '1', '', 

<cut>

> This gives me a record with a uid that is 1.
> 
> I then insert another record...
> ====================================================================== 
> =========== mysql> INSERT INTO users VALUES ( NULL, '', 

<cut>

> This results in a second record with a uid that is not 2, but rather 
> the max value...
> ====================================================================== 
> ===========
> mysql> select uid from users;
> +------------+
> | uid        |
> +------------+
> |          1 |
> | 2147483647 |
> +------------+
> 2 rows in set (0.00 sec)
> ====================================================================== 
> ===========
> 
> 
> What am I doing wrong here?

It looks as though a negative value at some point slipped
into the table. Is the table newly created?

DESCRIBE doesn't always give you all the details you need
to debug something like this. Try dumping the table definitions
using "mysqldump -d" and have a look at the CREATE definition.

If the table is indeed empty, you might want to re-import it
once again by using the dump, then re-entering the data above.

/ Carsten
--
Carsten H. Pedersen
keeper and maintainer of the bitbybit.dk MySQL FAQ
http://www.bitbybit.dk/mysqlfaq

---------------------------------------------------------------------
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