what is the difference between primary key & foreign key?
Answer Posted / pravin
The primary key of a relational table uniquely identifies
each record in the table. It can either be a normal
attribute that is guaranteed to be unique (such as Social
Security Number in a table with no more than one record per
person) or it can be generated by the DBMS (such as a
globally unique identifier, or GUID, in Microsoft SQL
Server). Primary keys may consist of a single attribute or
multiple attributes in combination.
Examples:
Imagine we have a STUDENTS table that contains a record for
each student at a university. The student's unique student
ID number would be a good choice for a primary key in the
STUDENTS table. The student's first and last name would not
be a good choice, as there is always the chance that more
than one student might have the same name.
Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
what is the need of indexing topic in oracle? where do we use in a Java project? any other option other than using this to get the same result where we use indexing ?
What are a cluster and non-cluster index?
What is tns name?
1) What is ONE_SIZE_FITS_ALL approach? 2) Explain the Common & Variable Header of DATA FILE? 3) What are the Drawbacks to using OMF DB? and the Advantages? 4) List out the Advantages of Undo T.spaces over the Undo SEGMENT? 5) Difference between the Temporary tablespace with TEMPFILE and the Tablespace with TEMPORARY Keyword? 6) What are the situation extents are freeing for reuse.
How to bring a tablespace online?
Can you have more than one content canvas view attached with a window ?
Can we create database in oracle using command line ?
State some uses of redo log files?
What happens internally when the user types userID/password@string in SQL PLUS Thanks-Bhaskar
How to recover a dropped table in oracle?
What are the restrictions on external table columns?
How do you get nicely formatted results from an oracle procedure that returns a reference cursor?
What is Redo Log Buffer in Oracle?
How to end the current transaction in oracle?
What's dateware house and what's clustor with practicle example