View Full Version : MySQL help
senewimala1988
05-23-2008, 09:52 AM
Mata table ekak MySQL valin create karanna one to enter Name ,Address,Contact No,Total Price.Meka thama mama type kala coding eka.Eth ekata error ekak enava..Eka hari gassala denavada???PLEASE!!!!!
create table Customer_Details(Name varchar(25),Address varchar(50),Contact_No int(10),Total_Price int(15));
senewimala1988
05-23-2008, 10:19 AM
This is da error
ERROR 1064:You have an error in your SQL syntax.Chace the manual that corresponds to your MySQL server version for rhe syntax to use near ' create table Customer_Details(Name varchar(30),Address varchar(
picsms
05-23-2008, 01:06 PM
This is da error
ERROR 1064:You have an error in your SQL syntax.Chace the manual that corresponds to your MySQL server version for rhe syntax to use near ' create table Customer_Details(Name varchar(30),Address varchar(
Hey Bos
I had Creadted in my local server and get the script for you. smal advice when ur creating Tables in any DBMS you should keep a Primarykey
i had created with primary key if u want keep other wise delet it
here the MySql Query
CREATE TABLE `Customer_Details` (
`Name` VARCHAR( 25 ) NOT NULL ,
`Address` VARCHAR( 50 ) NOT NULL ,
`Contact_No` INT( 10 ) NOT NULL ,
`Total_Price` INT( 15 ) NOT NULL ,
`Coustomer_Id` INT( 4 ) NOT NULL AUTO_INCREMENT ,
PRIMARY KEY ( `Coustomer_Id` )
) ENGINE = MYISAM
If you dont want with Primary Key Delet the line in Red in coming query
CREATE TABLE `Customer_Details` (
`Name` VARCHAR( 25 ) NOT NULL ,
`Address` VARCHAR( 50 ) NOT NULL ,
`Contact_No` INT( 10 ) NOT NULL ,
`Total_Price` INT( 15 ) NOT NULL ,
`Coustomer_Id` INT( 4 ) NOT NULL AUTO_INCREMENT ,
PRIMARY KEY ( `Coustomer_Id` )
) ENGINE = MYISAM
Note:-
Without Primary key creating a table is not profissional k. just my opinion
K bos i think you got anser for ur question.
Enjoy
vBulletin® v3.8.4, Copyright ©2000-2010, Jelsoft Enterprises Ltd.