Bugs item #1643845, was opened at 2007-01-24 21:43 Message generated for change (Tracker Item Submitted) made by Item Submitter You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=482468&aid=1643845&group_id=56967
Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: SQL/Core Group: SQL CVS Head Status: Open Resolution: None Priority: 5 Private: No Submitted By: Romulo Goncalves (romulog) Assigned to: Niels Nes (nielsnes) Summary: Delete primary keys Initial Comment: In this moment it is possible to delete values from a table with primary key which have foreign keys. Here is an example to show the bug: create table t1(id int, name varchar(1024)); alter table t1 add constraint id_p primary key(id); create table t2(id_f int, age int, foreign key(id_f) references t1(id)); alter table t2 add constraint age_p primary key(age); As you can see t2 has a foreign key (f_id) to the primary key in t1(id). I executed the following queries: [EMAIL PROTECTED] test]$ mclient sql>insert into t1 values(1,'romulo'); [ 1 ] sql>insert into t2 values(1,33); [ 1 ] sql>insert into t2 values(2,33); MAPI = [EMAIL PROTECTED]:50000 QUERY = insert into t2 values(2,33); ERROR = !SQLException:assert:INSERT INTO: PRIMARY KEY constraint 't2.age_p' violated sql> Until here no problem. However... sql>delete from t1 where id = 1; As you will see the operation is executed without sending an error message. if you select from t1 you can see the t1 status: sql>select * from t1; % sys.t1, sys.t1 # table_name % id, name # name % int, varchar # type % 1, 6 # length sql> Regards, Romulo ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=482468&aid=1643845&group_id=56967 ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys - and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ Monetdb-bugs mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/monetdb-bugs
