Issue comparing field values of type real equal to 0

Automate and integrate using the SQL comparison API

Issue comparing field values of type real equal to 0

Postby SQLAdminCJ » Mon Jun 25, 2012 7:41 am


I am having an issue with the SDK where it is generating diff queries to set real field values equal to 0 that already appear as 0 in both databases (i.e. this field is being registered as different when it is not different).

Perhaps, since the fields are of type real, they contain very small numbers that are appearing as 0 in SQL Server Management Studio?

In any case, how do I avoid having the SDK consider these fields different? Is there a parameter I can set? Please advise. Thanks.
Posts: 10
Joined: Wed Dec 28, 2011 1:03 am

Postby james.billings » Tue Jun 26, 2012 2:25 pm

Thanks for your post.
We've had issues in the past with FLOATs where a difference is seen due to SQL Data Compare not using the full precision when comparing. We added a comparison option in V10 to use the full precision and it looks like you can utilise this in the SDK too:

Code: Select all
ComparisonOptions.Default | ComparisonOptions.UseFullPrecisionForComparison

Not sure if this works for REAL though; but it's worth a try...
Posts: 1122
Joined: Wed Jun 16, 2010 10:10 am
Location: Red Gate

Return to SQL Comparison SDK Previous Versions

Who is online

Users browsing this forum: No registered users and 0 guests