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: 25571
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: Performance issue on this query
Next Topic: SQL%ROWCOUNT reporting 1 even though there is no records affected
Goto Forum:

Current Time: Sat Aug 19 17:37:51 CDT 2017

Total time taken to generate the page: 0.08741 seconds