Closed Thread
Results 1 to 4 of 4

Thread: phpmyadmin does wrong

  1. #1
    galaxyAbstractor's Avatar
    galaxyAbstractor is offline Community Advocate galaxyAbstractor is on a distinguished road
    Join Date
    Oct 2007
    Location
    Land of Null and Insanity
    Posts
    5,495

    phpmyadmin does wrong

    I want to make a table with 2 rows and 1 is auto increment. I used the phpMyAdmin UI, I didn't put any SQL in it and it says:

    CREATE TABLE `test`.`gadget` ( `gcode` VARCHAR( 20000 ) NOT NULL ,
    `id` VARCHAR( 20000 ) NOT NULL AUTO_INCREMENT ,
    PRIMARY KEY ( `id` )
    ) ENGINE = MYISAM
    MySQL sa:
    #1063 - Incorrect column specifier for column 'id'
    ^^This is what PhpMyAdmin does after I press save^^

    Is it a fault in my phpMyAdmin installation?

    But if I do without auto_increment it works...

  2. #2
    scorch94 is offline x10 Sophmore scorch94 is an unknown quantity at this point
    Join Date
    Sep 2007
    Posts
    228

    Re: phpmyadmin does wrong

    Try INT instead of VARCHAR (most people use integers for IDs anyway).

  3. #3
    galaxyAbstractor's Avatar
    galaxyAbstractor is offline Community Advocate galaxyAbstractor is on a distinguished road
    Join Date
    Oct 2007
    Location
    Land of Null and Insanity
    Posts
    5,495

    Re: phpmyadmin does wrong

    Quote Originally Posted by scorch94 View Post
    Try INT instead of VARCHAR (most people use integers for IDs anyway).
    INT has a limit to 255. Whatif I have more than 255 items? Wiuldn't work

  4. #4
    galaxyAbstractor's Avatar
    galaxyAbstractor is offline Community Advocate galaxyAbstractor is on a distinguished road
    Join Date
    Oct 2007
    Location
    Land of Null and Insanity
    Posts
    5,495

    Re: phpmyadmin does wrong

    Fixed. I just understanded it wrong. I thought if it was INT(11) it meant that number 11 was the largest number it could hold...

Closed Thread

Similar Threads

  1. Delete Database from phpMyAdmin
    By miyagiz in forum Free Hosting
    Replies: 3
    Last Post: 03-10-2008, 02:37 AM
  2. phpmyadmin wrong username and password?
    By shaunNO2007 in forum Free Hosting
    Replies: 0
    Last Post: 01-17-2008, 12:24 PM
  3. problem with phpmyadmin
    By Daiphron in forum Free Hosting
    Replies: 4
    Last Post: 01-15-2008, 12:27 AM
  4. Replies: 0
    Last Post: 12-27-2007, 03:16 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
x10hosting free hosting for the masses
dedicated servers