Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Mailing Lists -> Oracle-L -> Any Ideas
We have the query below running in a 9.2.0.6 DB We put the query into a 9208 instance and the Distinct works, looks as if there's a bug at play
SELECT shift.shiftid
FROM job, shift, lkshiftmachinestage, operation WHERE job.actualstartdt <= shift.todt AND job.actualenddt >= shift.fromdt AND lkshiftmachinestage.machinestageid = operation.machinestageid AND job.jobid = operation.jobid AND lkshiftmachinestage.shiftid = shift.shiftid AND shift.shiftid = 24548
And it returns 255 identical numbers. When I put in a distinct
SELECT DISTINCT shift.shiftid
FROM job, shift, lkshiftmachinestage, operation WHERE job.actualstartdt <= shift.todt AND job.actualenddt >= shift.fromdt AND lkshiftmachinestage.machinestageid = operation.machinestageid AND job.jobid = operation.jobid AND lkshiftmachinestage.shiftid = shift.shiftid AND shift.shiftid = 24548
I get "no rows found". Even tried making it a subquery
select distinct *
from
(
SELECT shift.shiftid
FROM job, shift, lkshiftmachinestage, operation
WHERE job.actualstartdt <= shift.todt
AND job.actualenddt >= shift.fromdt
AND lkshiftmachinestage.machinestageid = operation.machinestageid
AND job.jobid = operation.jobid
AND lkshiftmachinestage.shiftid = shift.shiftid
AND shift.shiftid = 24548
)
And still get nothing :-S
TIA
Larry
If the reader of this message is not the intended recipient, you are hereby notified that any dissemination, distribution or copying of this communication is strictly prohibited.
If you have received this communication in error, please resend this communication to the sender and delete the original message or any copy of it from your computer system.
Thank you.
-- http://www.freelists.org/webpage/oracle-lReceived on Thu Jul 19 2007 - 10:31:23 CDT
![]() |
![]() |