Primary key for SQL database? Is UNIQUE IDENTIFIER ok?

From: pmud (pmud_at_discussions.microsoft.com)
Date: 12/28/04


Date: Tue, 28 Dec 2004 07:45:06 -0800

I need to know like in MS Access we have an autonumber data type which can be
made the primary key. Is there a data type in SQL database also which can be
made the primary key & which is automatically filled by the database? Is
uniqueIdentifier a good choice & is it filled by the database itself?

I need this coz my table doesnt have a primary key & i need a primary key
for it.

-- 
pmud


Relevant Pages

  • Re: Key Violations in Append Queries
    ... the same data type. ... Normally, if a primary key or other unique index is created, it is because ... the design of the database requires uniqueness for the key involved. ... Whoever designed the database supposedly felt this was necessary. ...
    (microsoft.public.access.queries)
  • Re: SQL Express - Identity specification property - how to change
    ... FOO_ID int identity, ... Tony Rogerson, SQL Server MVP ... They are making unfortunately frequent use of the IDENTITY column in conjunction with Primary Key. ... IDENTITY has none of the properties of a data type because it is not a data type at all. ...
    (comp.databases.ms-sqlserver)
  • Re: Combo Box Design and/or Coding
    ... Primary Key: HotelID, Indexed, Yes (No Duplicates), Data Type: AutoNumber ... Primary Key: LocationID, Indexed, Yes, Data Type: AutoNumber ... nothing is being updated in tblHotelLocations. ...
    (microsoft.public.access.formscoding)
  • Re: Storing text from a combo box in a separate table
    ... --UserID Number data type, Long Integer, clear the 0 from its default value ... drag the primary key from Consumables_Info to the ConsID in ... --delete the textbox for ConsID ... something that lists who ordered what and when. ...
    (microsoft.public.access.gettingstarted)
  • Re: SQL Express - Identity specification property - how to change
    ... More than one column can have the same data type ... same vein that we can only give the PRIMARY KEY property to one column ... it got into SQL because we were ... basic data type property. ...
    (comp.databases.ms-sqlserver)