Hi guys,
I am trying to create a table in SQL Server 2005 through simple query which is as follows:
create table Appointment
{
Doc_ID numeric(4,0) references Patient(Pat_ID),
Pat_ID numeric(4,0) references Doctor(Doc_ID),
_Day day,
Date datetime,
Consultant_Name varchar(40),
primary key(Doc_ID,Pat_ID)
};
but i am getting the error:
Msg 102, Level 15, State 1, Line 2 Incorrect syntax near '{'
I know there is a little syntax mistake, but i am unable to figure out. I didnot find solution on google. Please help me, I am newbie.. Thanks in advance