what is the Foreign key? explain?
Answers were Sorted based on User's Feedback
Answer / gowrinag
FOREIGN KEY YFK (YNO) REFERENCES Y
ON DELETE CASCADE,
FOREIGN KEY ZFK (ZNO) REFERENCES Z
ON DELETE RESTRICT)
IN OZAGENDB.OZAGENTS;
ex:
CREATE TABLE YZ
(YNO CHAR(5) NOT NULL,
ZNO CHAR(5) NOT NULL,
QTYINTEGER,
PRIMARY KEY (YNO,ZNO),
FOREIGN KEY YFK (YNO) REFERENCES Y
ON DELETE CASCADE,
FOREIGN KEY ZFK (ZNO) REFERENCES Z
ON DELETE RESTRICT)
IN OZAGENDB.OZAGENTS;
---------+---------+---------+---------+---------
YNO ZNO QTY
---------+---------+---------+---------+--------
Y1 Z1 300
Y2 Z2 400
| Is This Answer Correct ? | 2 Yes | 1 No |
Answer / guest
A foreign key establishes the referential constraint
between a parent table and a dependent table
| Is This Answer Correct ? | 3 Yes | 3 No |
Hi. I am currently working as a application developer. I would like to persue a DB2 certification exam. Can anybody please provide me the details about this exam like Syllabus, Cost and how to take the certification?
Can a Db2 table data be retrived through JCL?
what is SPUFI ?
What happens to a cursor after a commit?
in column y record abc.v abc.s xyz.j abc.h i wan only abc columns how to retrieve thi records
What is the use of COMMAREA ?Minimum how much data we can pass from it?
What is query_cache_limit?
PLAN IS EXECUTABLE AND PACKAGE IS NOT EXECUTABLE . THEN WHAT IS THE USE OF PACKAGE?
2 Answers Tech Mahindra, Wipro,
What is an EXPLAIN in DB2. How and what is the steps followed in EXPLAIN command. Can all the queries be used in EXPLAIN command to check the performance.
When Can you be sure that a query will return only one row?
Mention a credible reason why select* is never given preference in an sql program that has been embedded.
What db2 400?