Home > other >  MySQL error 1064 on creating a table query
MySQL error 1064 on creating a table query

Time:12-25

CREATE TABLE `chuchutvlogin`. (
 `id` INT NOT NULL AUTO_INCREMENT , 
 `username` VARCHAR(20) NOT NULL , 
 `gender` CHAR(1) NOT NULL , 
 `email` VARCHAR(50) NOT NULL , 
 `password` VARCHAR(20) NOT NULL , 
 `number` BIGINT(10) NOT NULL , 
  PRIMARY KEY (`id`)
) ENGINE = InnoDB;

what's issue?

i was creating a login databse and error #1064 came syntax error in localhost phpmyadmnin

CodePudding user response:

Fix syntax error in your query, remove dot char after table name:

CREATE TABLE chuchutvlogin (
    id INT NOT NULL AUTO_INCREMENT,
    username VARCHAR(20) NOT NULL,
    gender CHAR(1) NOT NULL,
    email VARCHAR(50) NOT NULL,
    password VARCHAR(20) NOT NULL, 
    number BIGINT(10) NOT NULL,
    PRIMARY KEY (id)
) ENGINE = InnoDB;

dbfiddle

  • Related