[Mono-bugs] [Bug 650841] New: Filter DataTable.Select("column=4.4") misses for data type 'float'
bugzilla_noreply at novell.com
bugzilla_noreply at novell.com
Tue Nov 2 18:02:56 EDT 2010
https://bugzilla.novell.com/show_bug.cgi?id=650841
https://bugzilla.novell.com/show_bug.cgi?id=650841#c0
Summary: Filter DataTable.Select("column=4.4") misses for data
type 'float'
Classification: Mono
Product: Mono: Class Libraries
Version: 2.6.x
Platform: x86
OS/Version: Windows 7
Status: NEW
Severity: Normal
Priority: P5 - None
Component: Sys.Data
AssignedTo: mono-bugs at lists.ximian.com
ReportedBy: cvolzke at live.com.au
QAContact: mono-bugs at lists.ximian.com
Found By: ---
Blocker: ---
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US)
AppleWebKit/532.5 (KHTML, like Gecko) Chrome/4.1.249.1036 Safari/532.5
Filter DataTable.Select("column=4.4") misses for data type 'float'.
This is because of the way the Numeric class converts Single to Double
internally.
Reproducible: Always
Steps to Reproduce:
Test case
DataTable table = new DataTable();
DataColumn column = table.Columns.Add("column", typeof(float));
DataRow row = table.Rows.Add((float)4.4);
Debug.Assert((float)row[0] == (float)4.4);
DataRow[] results = table.Select("column=4.4");
Assert.AreEqual(1, results.Length);
Actual Results:
The filter string does not match
Expected Results:
The filter string matches
The problem is in the Numeric class which converts float to double.
--
Configure bugmail: https://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.
More information about the mono-bugs
mailing list