hello guys i am stuck in cluster and non cluster index i am read different articals about it but still i am not clear on it please help me to clear it
i have create one table like
create table Student (SId int not null identity(1,1) primary key,Firstname nvarchar(50),Lastname nvarchar(50),Gender nvarchar(6),MobileNo decimal(11,0),Address nvarchar(300),City nvarchar(50),DOB datetime, created DATETIME not null DEFAULT(getdate()));
What I have tried:
i have a Student Table i have wrote query for cluster and non cluster index given below
create clustered index Student_ind on Student(Firstname);
when i am run above query i have shown a error :Cannot create more than one clustered index on table 'Student'. Drop the existing clustered index 'PK__Student__CA195950D791869D' before creating another.
but i have create cluster first time then why this error occur
create index Student_no_ind on Student(created)
for execution i have used this command
exec SP_HELP Student
i have get output also but i dont understand it what kind of output it is