What is the difference between column level constraints and
table level constraints?
Answer Posted / chaitu
If constraint is defined at the column definition(refer the below exmpls) then it is known to be column level, where as table leevel constraints is defined at the especially incase of composite primary key or composite foriegn key.
Examples
----------
CREATE TABLE CLASS ( ROOM NUMBER(10) CONSTRAINT ID CHECK (ID BETWEEN 1 AND 2000),
..........
.........
........
.........);
Table level
==================
CREATE TABLE CLASS (
ROOM NUMBER(10) ,
SUBJECT VARCHAR2(200),
CODE VARCHAR2(50) NOT NULL, /* Column level constraint*/
ID NUMBER(8,2),
CLASS_DATE DATE,
CONSTRAINT PK_1 PRIMARY KEY (ROOM)); /* table level
| Is This Answer Correct ? | 30 Yes | 9 No |
Post New Answer View All Answers
What is an Oracle Instance?
How to define a sub function?
Explain the use of show option in imp command.
What is the difference between online and offline backups?
What is the use of oracle?
What do you mean by merge in oracle and how can we merge two tables?
What is a nvl function? How can it be used?
Can a parameter be passed to a cursor?
What is index in Oracle?
How many categories of data types?
Can you create a synonym without having a table?
What is a select query statement in oracle?
Point the difference between translate and replace?
what is IDE,DMV in sql server?
query optmization techniques and quwry analyser+projects+ppts