http://bugzilla.novell.com/show_bug.cgi?id=579824
http://bugzilla.novell.com/show_bug.cgi?id=579824#c0 Summary: DataTable.Select comparisons resulting in "NULL<>" return TRUE instead of FALSE Classification: Mono Product: Mono: Class Libraries Version: 2.4.x Platform: Other OS/Version: openSUSE 11.1 Status: NEW Severity: Normal Priority: P5 - None Component: Sys.Data AssignedTo: mono-bugs@lists.ximian.com ReportedBy: janvanderw...@gmail.com QAContact: mono-bugs@lists.ximian.com Found By: --- Blocker: --- Created an attachment (id=342358) --> (http://bugzilla.novell.com/attachment.cgi?id=342358) Source code to test with User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.2) Gecko/20100115 Firefox/3.6 (.NET CLR 3.5.30729) When a filter expression uses the NOT EQUAL operator on a column, rows with NULL in that column should not be returned, but they are returned on Mono. (NULL here is shorthand for DBNull.Value, not the keyword "null") Reproducible: Always Steps to Reproduce: 1. Create a datatable with columns "Name" (String) and "Subscribed" (Boolean) 2. Set some "Names" to valid values, leave some NULL. 3. Set some "Subscribed" to false, leave some NULL (don't use TRUE as this confuses the issue). 4. View the results of datatable.Select("Name<>'anything'"). 5. View the results of datatable.Select("Subscribed<>False"). Actual Results: 4. Rows with Name=NULL are also returned 5. Rows with Subscribed=NULL are also returned Expected Results: 4. Only rows with Name=<actual text, or empty string> to be returned 5. Only rows with Subscribed=True to be returned i.e. if the operation is <> and any of the operands is NULL, the expression should evaluate to false (even "Name<>Null" is FALSE and should NOT return the rows where the name is NULL - the correct expression for this is "Name Is Not Null") (Mono throws an exception "Expression 'Subscribed<>Null' is invalid", but .NET doesn't) -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the QA contact for the bug. You are the assignee for the bug. _______________________________________________ mono-bugs maillist - mono-bugs@lists.ximian.com http://lists.ximian.com/mailman/listinfo/mono-bugs