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...


What is Foreign Key?
What is the main difference between primary key and Foreign
Key ?
How Foreign Key can be defined?
Is Foreign key is used to join two or more table?

Answers were Sorted based on User's Feedback



What is Foreign Key? What is the main difference between primary key and Foreign Key ? How Foreig..

Answer / sunil kumar

Foreign key represents the relationship between two tables.
A foreign key in a table whose value is derived from the
primary key from some other table.The table in which foreign
key is defined is called a foreign table or detailed table.
The table that defines the primary key and is referenced by
the foreign table is called primary table or master table.
Difference between primary key and foreign key is that
primary key must contain a value,must not contain null
value,redundant value and foreign key can contain redundant
value.
Foreign key is defined as= create table employee(empno int
not null,empname char(40)not null,dept char(20),foreign
key(dept)references department(deptno))
Yes Foreign key is used t join two or more tables.

Is This Answer Correct ?    13 Yes 0 No

What is Foreign Key? What is the main difference between primary key and Foreign Key ? How Foreig..

Answer / amol kharat

Sunil is absolutely right.

foreign key may be null but primary key is not null, foeign
key is the reference to other table.

Foreign key is a primary key of reference table.

Is This Answer Correct ?    3 Yes 0 No

What is Foreign Key? What is the main difference between primary key and Foreign Key ? How Foreig..

Answer / balaji ganesh doddi

Foreign key is establish the relationship between two
tables.
Primary key is used to uniqly identified by the data into a
table.
The major differences are
Primary key should not contain null values and redundant
value.
Foreign key can contain redundant value.

Foreign key is a primary key of reference table.

Foreign key is defined as= create table employee(empno int
not null,empname char(40)not null,dept char(20),foreign
key(dept)references department(deptno))
Yes Foreign key is used t join two or more tables.

Is This Answer Correct ?    1 Yes 0 No

What is Foreign Key? What is the main difference between primary key and Foreign Key ? How Foreig..

Answer / guest

yes

Is This Answer Correct ?    0 Yes 4 No

Post New Answer

More MySQL Interview Questions

How many ways we can retrieve the date in result set of mysql using php?

0 Answers  


How do I change directories in mysql?

0 Answers  


What is mysql database used for?

0 Answers  


What is a trigger in mysql?

0 Answers  


What language is mysql written in?

0 Answers  


at first i'm using datediff('d', a.due_date, current_date); but it takes too long to get the result but how can i subtract the current_date - a.due_date and still get the same result like when i use datediff? thank you

1 Answers  


How to load data from a text file into a table?

7 Answers   Sasaa,


How do you concatenate strings in mysql?

0 Answers  


What are the technical specifications of mysql?

0 Answers  


Why mysql is open source?

0 Answers  


What is the use of mysqli_fetch_array?

0 Answers  


What is a longblob?

0 Answers  


Categories