Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> "select in" statment returns wrong number of rows
I've got a SQL-Sttment with many "select in (....)" statements. When
I'm executing this statement, Oracle 9.2 returns me a different number
of rows in comparison to the the statement with explicit written
"where clauses" (where .... = .... or ... ... or .....).
Is there a difference between select in clauses and or-clauses?
An other effect when using select in clauses with oracle object functions is, that it takes a very long time.
example: select * from table(myvirtualtable(....))vt , othertable where vt.atr = othertable.atr and othertable.atr in (........)
the workaround
select * from table(myvirtualtable(....))vt , othertable where vt.atr
= othertable.atr and
othertable.atr = ....
or othertable.atr = .....
or .....
works faster.
why?
greetings
Martin
Received on Tue Feb 22 2005 - 02:53:26 CST