Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

New Table - Do I Need an Identity Col ?

Status
Not open for further replies.

JohnBates

MIS
Feb 27, 2000
1,995
0
0
US
Hi SQL Servers,

This new SQL Server 2000 table contains phone call data collected from our PBX system.
The main columns are: CallDate, PhoneExtension, AuthCode (its a PIN #) and RecNo (this is a record number but it is NOT unique - each days call data starts with RecNo 1, that's just the way it is)

Currently, there is no Identity col in this table.

Should I add an Identity column as the PrimaryKey ?
- OR- would it be better to use CallDate + RecNo as the PK?

Please give your reason.

300,000 rows in table now - it will grow by 70,000 each month. (obviously I will have to purge some months or years data at some point)

Will Select/Query the data by : - CallDate
or - AuthCode
or - PhoneExtension

And... performance is probably more important than data integrity.

What do you think? Based on these facts, should I add an Identity / GUID column to this table ?

Thanks for your feedback. John



 
I would use CallDate + RecNo as the PK, for the only reason that for searching on the table it will be quicker. A identity column would not be too helpful to you in this instance unless you where going to use it in every day life.

This is my opinion hope it is usefull.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top