March 17, 2004 at 3:07 am
Hello...i have trouble trying to create this table.
Can someone tell me what's wrong with it?
create table users
(
user_id int unsigned not null auto_increment primary key,
username varchar(15) not null,
password varchar(8) not null,
fullname varchar(50) not null,
stud_id varchar(10) not null,
intake varchar(9),
email varchar(60),
major varchar(60),
date_reg date,
);
would greatly appreciate it!!
eat when you can and not when you cannot.
March 17, 2004 at 5:05 am
You just need to make it SQL Server specific..
create table users
(
user_id int not null identity primary key,
username varchar(15) not null,
password varchar(8) not null,
fullname varchar(50) not null,
stud_id varchar(10) not null,
intake varchar(9),
email varchar(60),
major varchar(60),
date_reg datetime,
)
identity is the equivalent of auto_increment
no unsigned int in SQL Server...int takes values from -2^31 to 2^31 -1
no only-date data type in SQL Server (as yet)...you'll need to use datetime (accuracy to 1/300 of a second) or smalldatetime (accuracy to 1 minute)....
if you've got BOL (Books online) then a search on data types will give you loads of info....
March 19, 2004 at 10:43 pm
hey...thanks
will go and try it out!
eat when you can and not when you cannot.
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply