Home » SQL & PL/SQL » SQL & PL/SQL » data mismatch issue
data mismatch issue [message #218289] Wed, 07 February 2007 10:57 Go to next message
Messages: 1
Registered: December 2005
Location: Bagalore
Junior Member
Dear All,
I am facing a data mismatch issue.
A stored procedure is converted from SQL Server 2005 to Oracle 10g.
The SP does select operation after joining 7 tables and has a where clause.

A required criterion is for given set of input values, get the same output from Oracle SP, when compared with SQL Server SP output. This output is used by another module to perform the calculations. It is expecting the same result.
Currently it is giving same number of records and each record when compared individually is same except the order.
There is an order by clause on the first and tenth column of select clause. Both Oracle and SQL Server output is fine with respect to 1st and 10th columns but data after these 2 levels of sorting is not matching.

Please let me know how to fix this issue.

With regards,
Re: data mismatch issue [message #218318 is a reply to message #218289] Wed, 07 February 2007 13:28 Go to previous message
Messages: 24975
Registered: January 2009
Location: SoCal
Senior Member
>"not matching"
The ONLY way to guarentee "order" is to use ORDER BY clause.
If you require ORDER based upon more than the 2 columns, then you need to EXPLICITLY specify the additional columns.
Previous Topic: remove duplicates from a query containing more than 1 table
Next Topic: left outer join query.
Goto Forum:

Current Time: Fri Oct 28 11:15:32 CDT 2016

Total time taken to generate the page: 0.20686 seconds