Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

is there more the two primary key in a single table?

Answer Posted / selvaraj.v

In SQL Server 2000,

Query :
-------

create table BookDetails
(
Book_ID int identity(1,1) not null primary key,
Book_Title varchar(20),
Book_Type varchar(15),
Book_Author varchar(25),
Book_Edition float,
Book_Publisher varchar(20),
Book_Pub_Year datetime,
Book_Price int primary key
)

Answer :
--------

Server: Msg 8110, Level 16, State 1, Line 1
Cannot add multiple PRIMARY KEY constraints to
table 'BookDetails'.

Reply Answer:
-------------
So,Can't Create more Primary Keys in a Table.

Is This Answer Correct ?    13 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is sql server replication? : sql server replication

991


How to generate create table script on an existing table in ms sql server?

1143


What is transactional replication?

968


Explain the cursor lock types?

1058


What stored by the master? : sql server database administration

1111


Find columns used in stored procedure?

991


Explain how you can deploy an SSRS report?

150


What is use of except clause? How does it differ from not in clause?

1020


What are the advantages of using cte?

1016


What are scheduled tasks in sql server?

1085


What is model database? : SQL Server Architecture

1133


how to do partition in sqlserver

2476


What is the cartesian product of the table?

958


List the different types of joins?

1011


What are a database and a data warehouse?

1022