Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: A simple case to make Oracle805 fail

Re: A simple case to make Oracle805 fail

From: Doug Cowles <dcowles_at_bigfoot.com>
Date: Tue, 18 May 1999 16:57:08 -0400
Message-ID: <3741D424.830BF792@bigfoot.com>


Actually, a column that is both a primary and a foreign key is very common in datawarehouse applications. However, in this instance, it is a foreign key to it's own table, which seems very bizarre to me.

Sybrand Bakker wrote:

> Simple?
> It is the first example I see of a column participating in both the primary
> key and a foreign key.
> IMHO this is
> a) bad database design
> b) why do you think Oracle will be able to deal with it?
> If this is a bug, it is a bug it is allowed to create such foreign key.
> The Ora-600 clearly arises during constraint validation. Consult the trace
> file in the user dump directory for further details and call support. That's
> the only sensible advise I can give you, but they will probably reply the
> same way I do.
>
> Best regards,
>
> Sybrand Bakker, Oracle DBA
>
> gzhu_at_calicotech.com wrote in message <7hqnli$hh6$1_at_nnrp1.deja.com>...
> >Have you run into following problem ? Any idea on how to solve it
> >(patch#, etc). This was running on Solaris 2.6.
> >
> >
> >Oracle8 Release 8.0.5.0.0 - Production
> >PL/SQL Release 8.0.5.0.0 - Production
> >SQLWKS> create table ora600 (key1 int, key2 int, constraint ora600_PRIM
> >primary key (key1, key2), col3 int, constraint ora600_FOR foreign key
> >(key1, col3) references ora600 (key1, key2) );
> >Statement processed.
> >SQLWKS> create index ora600_IDX on ora600 (key1);
> >Statement processed.
> >SQLWKS> insert into ora600 (key1, key2) values (1, 2);
> >1 row processed.
> >SQLWKS> insert into ora600 (key1, key2, col3) values (2, 1, 1);
> >1 row processed.
> >SQLWKS> delete from ora600 where key1 = 1
> > 2>
> >ORA-00600: internal error code, arguments: [12700], [2686], [25166457],
> >[0], [], [], [], []
> >
> >
> >--== Sent via Deja.com http://www.deja.com/ ==--
> >---Share what you know. Learn what you don't.---
> >
Received on Tue May 18 1999 - 15:57:08 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US