primary key


Also found in: Acronyms.

primary key

[′prī‚mer·ē ′kē]
(computer science)
A key that identifies a record or portion of a record and determines the sequence of records in a file or other data structure.

primary key

(database)
A unique identifier, often an integer, that labels a certain row in a table of a relational database.

When this value occurs in other tables as a reference to a particular row in the first table it is called a "foreign key".

Some RDBMSes can generate a new unique identifier each time a new row is inserted, others merely allow a column to be constrained to contain unique values.

A table may have multiple candidate keys, from which the primary key is chosen. The primary key should be an arbitrary value, such as an autoincrementing integer. This avoids dependence on uniqueness, permanence and format of existing columns with real-world meaning (e.g. a person's name) or other external identifier (e.g. social security number).

There should be enough possible primary key values to cater for the current and expected number of rows, bearing in mind that a wider column will generally be slower to process.

primary key

The column (field) in a relational database that uniquely identifies the row in the table. For example, account number is often a primary key. A "composite primary key" or "super key" is made up of two or more columns such as account number + name. See candidate key.
References in periodicals archive ?
This work has mainly the following major advantages: (i) the general and original definition of normal forms is used, (ii) the removal of redundant dependencies, (iii) in all phases, the computation of attributes closure are minimized compared to other algorithms although using a restricted definition of normal forms, and (iv) a primary key is determined for any generated relation.
Ensure all primary keys, foreign keys, and referential integrity constraints are clearly set.
8, "1" indicates that the query "Select 'Name' by 'ID'" is allowed to be executed and, on the basis of this data request, the data element "Name" can be matched using the data element "ID." Since the ID was the primary key in the database, we considered it as a unique characteristic in our example.
The second case is presented below: Gene_Product Database: GeneProduct relation ID Symbol DBRef Species Int Primary Key Varchar2 Varchar2 Integer Foreign Key Foreign Key Type Full_Name Varchar2 Char Genome Database: Genome relation Gene_ID Species CHR Strend Int Primary Key Int Foreign Key Varchar2 Int Gene_Name Description Varchar2 Varchar2 Global Schema: Our proposed model ID Symbol Dbxref Species Type CHR Strend Description Full_Name Global Schema: [8, 13] ID Symbol Species Type Full_Name CHR Strend and Description DBxref
We assume that the primary Key is intact because dropping it may cause loss of important data.
This development was crucial as data is the primary key to success that makes all the algorithms work.
In subtable 1 of Table 13, the reference number of an entity is the primary key that can be uniquely identified to represent an individual row field in the table.
Coach Micky Arthur insists "fitness is the primary key to Inzamam-ul-Haq success in modern day cricket", and says the players will go to a fitness boot camp in Pakistan as soon as the Champions Trophy finishes.
The primary key of the history table is the union of the primary key of the present table and the time_range attribute of the history table.
And that, she says, is part of the primary key to success.

Full browser ?