Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi there,
There is an issue with role permissions that is being worked on at the moment.
If you are having trouble with access or permissions on regional forums please post here to get access: https://www.boards.ie/discussion/2058365403/you-do-not-have-permission-for-that#latest

A simple SQL error

  • 11-03-2004 9:53pm
    #1
    Closed Accounts Posts: 414 ✭✭


    Ok trying to create this table for a signup form in php. Keep getting this error messages, anyone tell me what going on?

    SQL-query :

    CREATE TABLE `users` (

    `user_id` INT( 12 ) DEFAULT '0' NOT NULL AUTO_INCREMENT ,
    `username` VARCHAR( 50 ) NOT NULL ,
    `password` VARCHAR( 50 ) NOT NULL ,
    `f_name` VARCHAR( 50 ) NOT NULL ,
    `l_name` VARCHAR( 50 ) NOT NULL ,
    `email ` VARCHAR( 92 ) NOT NULL ,
    `gender` VARCHAR( 40 ) NOT NULL ,
    `birthday` DATE( 40 ) NOT NULL ,
    `region` VARCHAR( 60 ) NOT NULL ,
    `find` VARCHAR( 80 ) NOT NULL ,
    `zip` VARCHAR( 40 ) NOT NULL ,
    `country` VARCHAR( 50 ) NOT NULL ,
    `check` VARCHAR( 50 ) NOT NULL ,
    PRIMARY KEY ( `user_id` )
    )

    MySQL said:


    You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near '(40) NOT NULL, `region` VARCHAR(60) NOT NULL, `find` VARCHAR(80


Comments

  • Registered Users, Registered Users 2 Posts: 102 ✭✭OmeGar


    the only thing that jumps out is that you are using the Date Datastructure, are you sure you are putting in the right number of varibles?

    it's all i can see.....maybe i should leave it someone who knows SQL


  • Closed Accounts Posts: 414 ✭✭Divine


    ok OmeGar i just checked up dates there, yeah i should have had them not set at anything. Cheers for that.!!


Advertisement