View Single Post

   
  #2 (permalink)  
Old 02-28-2008, 07:06 AM
Carlos Proal
 
Posts: n/a
Default Re: Creating a Table With a Default


It makes no sense to use a default value with an auto_increment
attribute, which means, the default value is the auto-incremented value.

Carlos


Al Sparks wrote:
> I'm trying to install ProBIND, and I'm running mysql 4.1.20.
>
> One of the ProBIND install scripts calls for tables to be created in MySQL, and I've culled it down to this:
>
> mysql> CREATE TABLE zones (
> -> id INT(11) DEFAULT '1' NOT NULL AUTO_INCREMENT,
> -> PRIMARY KEY (id)
> -> );
> ERROR 1067 (42000): Invalid default value for 'id'
>
>
> I've tried double quotes, changing it to INT(1), and still I get that error.
>
> Any hints?
> === Al
>
>
>
>


Reply With Quote