Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Foreign Key ON DELETE RESTRICT

2681546Sep 8 2014 — edited Sep 8 2014

Hi,

I m getting error while using foreign key, could you let me know if there is any syntax error.

CREATE TABLE grade(course_no  VARCHAR2(33) NOT NULL,

                                 student_id VARCHAR2(33) NOT NULL,

                                 grade VARCHAR2(2),

                                 CONSTRAINT FK_COURSE

                                 FOREIGN KEY (course_no)  REFERENCES course(course_no)   ON DELETE RESTRICT

                                );

Error report:

SQL Error: ORA-00905: missing keyword

Thanks

This post has been answered by John Spencer on Sep 8 2014
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Oct 6 2014
Added on Sep 8 2014
1 comment
2,093 views