Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 urgent help plz

Author  Topic 

charles1309
Starting Member

15 Posts

Posted - 2007-11-21 : 07:23:38
can anyonetell me why my database giving me the follwing error, when i try to dropthe relationship:
ORA-02443: Cannot drop constraint - nonexistent constrain


i have used this script to drop my realtionship -
ALTER TABLE result DROP CONSTRAINT moduleid_FK;

i looked on the net, it says make sure the constrain name is right, i did and its right... why my sql giving me this error please..

CREATE TABLE STUDENT
(StudID char(4) NOT NULL ,
StudfName varchar(30),
StudSname varchar(30),
StudDOB varchar(30),
StudHouseNo varchar(30),
StudStreetName varchar(30),
studcity varchar(30),
StudPostcode varchar(30),
StudPhoneNo varchar(30),
StudNextofKind varchar(30),
StudNextofKinContact varchar(30),
PRIMARY KEY (StudID));


CREATE TABLE COURSE
(CourseID char(4) NOT NULL,
StudID char(4) NOT NULL,
CourseName varchar(30),
Courselength varchar(30),
CourseDegreeType varchar(15),
PRIMARY KEY (CourseID),
FOREIGN KEY (StudID) REFERENCES student (StudID));



CREATE TABLE RESULT
(ResultID char(4) NOT NULL,
STUDID CHAR(4) NOT NULL,
ModuleID char(4) NOT NULL,
Module1Result varchar(15),
Module2Result varchar(15),
Module3Result varchar(15),
PRIMARY KEY (ResultID),
FOREIGN KEY (studID) REFERENCES student(studID));



CREATE TABLE MODULE
(ModuleID char(4) NOT NULL,
ResultID char(4) NOT NULL,
ATTENDANCEID char(4) NOT NULL,
ModuleName1 varchar(45),
ModuleName2 varchar(45),
ModuleName3 varchar(45),
ModuleCode varchar(6),
PRIMARY KEY (ModuleID),
FOREIGN KEY (ResultID) REFERENCES RESULT(ResultID));


ALTER TABLE RESULT
ADD FOREIGN KEY (moduleID) REFERENCES module(moduleID);



charles

khtan
In (Som, Ni, Yak)

17689 Posts

Posted - 2007-11-21 : 07:26:32
This is a Microsoft SQL Server forum site. You are using Oracle. Please try to post over at dbforums.com


KH
[spoiler]Time is always against us[/spoiler]

Go to Top of Page

madhivanan
Premature Yak Congratulator

22864 Posts

Posted - 2007-11-21 : 07:27:18
post at www.dbforums.com or www.Orafaq.com

Madhivanan

Failing to plan is Planning to fail
Go to Top of Page

charles1309
Starting Member

15 Posts

Posted - 2007-11-21 : 07:35:37
can you people help me without redirecting... you know about it , why not help me brotheres? please understand my urgency

thanx

charles
Go to Top of Page

madhivanan
Premature Yak Congratulator

22864 Posts

Posted - 2007-11-21 : 07:37:46
Can you run this in ORACLE?

Select top 1 * from (select 23 as n union all select 5676) as t

Madhivanan

Failing to plan is Planning to fail
Go to Top of Page

charles1309
Starting Member

15 Posts

Posted - 2007-11-21 : 07:40:28
yes i do, but do i need to change anything on the code or just copy and paste that into my sql?

charles
Go to Top of Page

khtan
In (Som, Ni, Yak)

17689 Posts

Posted - 2007-11-21 : 07:45:34
Why not just posting over there ? It is not that we don't want to help you. It is just that most of the member here have experience in MS SQL Server and few also have experience in Oracle. What we advice you should work in MS SQLServer but MAY NOT work in Oracle !


KH
[spoiler]Time is always against us[/spoiler]

Go to Top of Page

charles1309
Starting Member

15 Posts

Posted - 2007-11-21 : 07:46:09
damn, i didnt know you are tamil too.. mee too brother... may i add you on yahoo. if you dont mind. your id please... nice to see tamils everywhere

charles
Go to Top of Page

madhivanan
Premature Yak Congratulator

22864 Posts

Posted - 2007-11-21 : 07:47:06
quote:
Originally posted by charles1309

yes i do, but do i need to change anything on the code or just copy and paste that into my sql?

charles


Just copy and paste
It wont work there becuase syntax slightly differs in both SQL Server and ORACLE
So as said, post your question at Oracle forums for better answer

Madhivanan

Failing to plan is Planning to fail
Go to Top of Page

madhivanan
Premature Yak Congratulator

22864 Posts

Posted - 2007-11-21 : 07:52:38
quote:
Originally posted by charles1309

damn, i didnt know you are tamil too.. mee too brother... may i add you on yahoo. if you dont mind. your id please... nice to see tamils everywhere

charles




Madhivanan

Failing to plan is Planning to fail
Go to Top of Page

charles1309
Starting Member

15 Posts

Posted - 2007-11-21 : 07:57:59
yuo dont trust it lol...lets saY VANAKKAM then... anyway those people on the other forumn are so slow... they tkae ages to reply


charles
Go to Top of Page

khtan
In (Som, Ni, Yak)

17689 Posts

Posted - 2007-11-21 : 08:08:50
quote:
Originally posted by charles1309

yuo dont trust it lol...lets saY VANAKKAM then... anyway those people on the other forumn are so slow... they tkae ages to reply

charles



Then maybe you should switch to using MS SQL Server ?


KH
[spoiler]Time is always against us[/spoiler]

Go to Top of Page

madhivanan
Premature Yak Congratulator

22864 Posts

Posted - 2007-11-21 : 08:11:15
quote:
Originally posted by charles1309

yuo dont trust it lol...lets saY VANAKKAM then... anyway those people on the other forumn are so slow... they tkae ages to reply


charles


Nandri

As specified in the error, double check if the constraint name is correct for that table

Madhivanan

Failing to plan is Planning to fail
Go to Top of Page

charles1309
Starting Member

15 Posts

Posted - 2007-11-21 : 20:09:48
u know what did i do lol.... deintalled oracle, and reinstalled ... all my table and relationship done.... the real battle for query starts tomrw


charles
Go to Top of Page

khtan
In (Som, Ni, Yak)

17689 Posts

Posted - 2007-11-21 : 20:38:50
should take my advice
quote:

deintalled oracle, and reinstalled MS SQL Server


Then you will get more help over here


KH
[spoiler]Time is always against us[/spoiler]

Go to Top of Page
   

- Advertisement -