#1
  1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2011
    Posts
    1
    Rep Power
    0

    ORA-02253: constraint specification not allowed here


    SQL> create table emp_column_level_cons(empno number(4) constraint empcol_empno_pk primary key,
    2 ename varchar2(15) unique,
    3 job varchar2(20) not null,
    4 sal number(7,2) check (sal between 1500 and 25000),
    5 deptno number(4) constraint empcol_deptno_fk foreign key re
    ferences dept(deptno) on delete cascade);
    deptno number(4) constraint empcol_deptno_fk foreign key references dept(deptno) on delete c
    *
    ERROR at line 5:
    ORA-02253: constraint specification not allowed here

    ================================================
    Please suggest.
    Thanks in advance
  2. #2
  3. Humble Learner
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jul 2007
    Location
    Bangalore, India
    Posts
    280
    Rep Power
    120
    please read more in the following link.

    http://download.oracle.com/docs/cd/B19306_01/server.102/b14200/statements_7002.htm

IMN logo majestic logo threadwatch logo seochat tools logo