Bug #12469 | Group by did not return the correct result when there is a NULL value | ||
---|---|---|---|
Submitted: | 9 Aug 2005 17:21 | Modified: | 10 Aug 2005 15:23 |
Reporter: | Dorn Bhechsonggram | Email Updates: | |
Status: | Not a Bug | Impact on me: | |
Category: | MySQL Server | Severity: | S2 (Serious) |
Version: | 4.1.11-standard | OS: | Linux (Fedora Core 1) |
Assigned to: | CPU Architecture: | Any |
[9 Aug 2005 17:21]
Dorn Bhechsonggram
[10 Aug 2005 15:23]
Aleksey Kishkin
Hi! in your example you assumed that NULL != 'Y' But as the matter of fact, according to SQL standarts the only operation 'is NULL' valid for NULL comparision. All other operation with NULL values return NULL (not boolean value) So in your example I believe you should use ... where col_b2 !='Y' or col_b2 is NULL ..