How do I create a table MANAGER (EMP-NO, MANAGER) where
MANAGER is a foreign key which references to EMP-NO in the
same table? Give the exact DDL.
Answer Posted / sahil garg
CREATE TABLE TB_MANAGER
(EMPNO CHAR(6) PRIMARY KEY ,
MANAGER CHAR(6) );
ALTER TABLE TB_MANAGER
ADD CONSTRAINT TB_FK FOREIGN KEY (MANAGER) REFERENCES
TB_MANAGER(EMPNO);
| Is This Answer Correct ? | 2 Yes | 2 No |
Post New Answer View All Answers
How do you simulate the explain of an embedded sql statement in spufi/qmf?
What is database alias db2?
What do you mean by storage group (stogroup)?
Mention the location where the output received from explain statement is stored.
Explain the contents that are a part of dclgen.
For a db2 column that is being defined as decimal (11, 2), discuss the cobol picture clause.
What is the difference between oracle and db2?
What is the difference between drop table and delete table?
How many databases can be created inside an instance in db2 ?
What is db2 connect?
Define data page.
Which command is used to connect to a database in DB2 ? Give the Syntax.
What is the cobol picture clause of the db2 data types date, time, timestamp?
What is dbrm? When it will be created?
Explain about rct.