aspose file tools*
The moose likes JDBC and the fly likes How to delete foreign key without name in Oracle Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC
Bookmark "How to delete foreign key without name in Oracle" Watch "How to delete foreign key without name in Oracle" New topic
Author

How to delete foreign key without name in Oracle

RabiDas Sharma
Ranch Hand

Joined: Nov 18, 2013
Posts: 65
Hi everyone,
I forgot to give name of foreign key constraint.
i.e,
I added Foreign key constraint in the following way:

ALTER TABLE Result1
ADD foreign key (stud_id) references Student(stud_id);

How I can drop the above foreign key constraint...???


thanks
with regards
Heena Agarwal
Ranch Hand

Joined: Dec 25, 2013
Posts: 254
    
    4
Query the user_constraints table to get the constraint_name.

Then run an alter table query that will drop that constraint.

 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How to delete foreign key without name in Oracle
 
Similar Threads
Syntax error for Access Database
error: Parameter index out of range (3 > number of parameters, which is 2).
complex table column type
a different object with the same identifier value was already associated with the session: [ValueObj
Need clarification in Many to one Mapping- Please help.