Bug #8934 | DOUBLE and DECIMAL comparison fails on Windows | ||
---|---|---|---|
Submitted: | 3 Mar 2005 22:58 | Modified: | 4 Mar 2005 4:20 |
Reporter: | Bicho Verde | Email Updates: | |
Status: | Not a Bug | Impact on me: | |
Category: | MySQL Server | Severity: | S2 (Serious) |
Version: | 4.1.10-nt | OS: | Windows (Windows XP and 2003) |
Assigned to: | CPU Architecture: | Any |
[3 Mar 2005 22:58]
Bicho Verde
[3 Mar 2005 23:01]
Bicho Verde
The workaround would be using ROUND(): SELECT * FROM testtable WHERE ROUND(col1,2) <> ROUND(col2,2);
[4 Mar 2005 4:20]
MySQL Verification Team
This behavior can be expected when envolving floating-point numbers. Please see: http://dev.mysql.com/doc/mysql/en/problems-with-float.html