Hi,
Can I please have the best answers for the below questions. No matter how much I read and study somehow they seem to get the better of me!!!
SQL source statements for which two of the following are stored in the system catalog?
A. Views
B. Tables
C. Indexes
D. Triggers
E. Constraints
Given the following transaction in an embedded SQL application:
CREATE TABLE dwaine.mytab (col1 INT, col2 INT)
INSERT INTO dwaine.mytab VALUES (1,2)
INSERT INTO dwaine.mytab VALUES (4,3)
ROLLBACK
What is the result of issuing the following statement?
SELECT * FROM dwaine.mytab
A. SQLCODE -204 indicating that "DWAINE.MYTAB" is an undefined name.
B. COL1 COL2
------------ -----------
0 record(s) selected.
C. COL1 COL2
------------ -----------
1 2 1 record(s) selected.
D. COL1 COL2
------------ -----------
1 2
4 3 2 record(s) selected.
Select the best answer.
Given the following statements:
CREATE TABLE t1 (id INTEGER, CONSTRAINT chkid CHECK (id<100))
INSERT INTO t1 VALUES (100)
COMMIT
Which of the following occurs as a result of issuing the statements?
A. The row is inserted with ID having a NULL value.
B. The row is inserted with ID having a value of 100.
C. The row insertion with a value of 100 for ID is rejected.
D. The trigger called chkid is activated to validate the data.
Thanks
Nitin.