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

Home -> Community -> Usenet -> c.d.o.misc -> Distinct query not working after database upgrade!!

Distinct query not working after database upgrade!!

From: The J Man <jonathan.keenan_at_gmail.com>
Date: 31 Jul 2006 12:45:04 -0700
Message-ID: <1154375104.418391.99630@i42g2000cwa.googlegroups.com>


Hey there,
i would really appreciate some help as this is driving me crazy!!!! I have a query that runs over two tables. (these are simplified versions!)

Table A AID text


               1     blah
               2     foobar

Table B    BID       AID     text                     date

-----------------------------------------------------------------
1 1 blah date x 2 1 more blah date y 3 1 even more blah date z

Simply put the query i used to run was:
SELECT DISTINCT A.AID, A.TEXT FROM A, B WHERE A.ID = B.ID AND mydate >= BID.date.
Using Oracle 10g.1 this query used to work perfect where it would return just one row of AID and text.
My DBA recently upgraded to Oracle 10g.2 and all hell broke loose in the system! This query no longer works at all, and no amount of tinkering i do i cannot get it to work. this query will now return every row in table B that has the unique Id of table A. It is as if the distinct clause has just stopped working.

this is driving me nuts and i would be glad if someone could help me. Even if its to say "hey dummy, of course thats not gonna work you need to do this" :-)

Thank you,
J. Received on Mon Jul 31 2006 - 14:45:04 CDT

Original text of this message

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