ordering of data different in Oracle8i compared to Oracle 7 [message #52034] |
Thu, 27 June 2002 06:56 |
Emma
Messages: 12 Registered: November 2001
|
Junior Member |
|
|
Does anybody know any thing about this :
I have migrated an ORacle 7 db to ORacle 8.1.7
and have been runnig the two databases in parallel.
However, I have noticed that when I run the same
query against the two databases that the query results from the Oracle 8.1.7 database are in a different order to the ORacle 7 db.
There has been no change to indexes.
Thanks in advance
|
|
|
Re: ordering of data different in Oracle8i compared to Oracle 7 [message #52041 is a reply to message #52034] |
Thu, 27 June 2002 12:55 |
andrew again
Messages: 2577 Registered: March 2000
|
Senior Member |
|
|
You should assume NOTHING about the ordering of data coming back from a query unless you have an order by statement. Even a "group by" or "distinct" statement does not imply that sorting of the result will take place. The order that data was entered into a table has very little to do with the order the data is retrieved - even with a full table scan. If you have a "order by" then you should look at the NLS* parameters (select * from v$paramter where...). Compare the values on the two instances.
Also - it's possible to sort NULLs either first or last in a order by statement.
|
|
|