Searching on float fields does not work properly
Bug #634634 reported by
Albert Cervera i Areny - http://www.NaN-tic.com
This bug affects 3 people
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Odoo Server (MOVED TO GITHUB) |
Confirmed
|
Wishlist
|
OpenERP's Framework R&D |
Bug Description
Trying to search with [('float_
WHERE float_field = 3.2800012
which will not exist.
The attached patch, checks if field is of type float and allows [('float_
Related branches
Changed in openobject-server: | |
status: | New → Confirmed |
Changed in openobject-server: | |
importance: | Undecided → Medium |
assignee: | nobody → OpenERP's Framework R&D (openerp-dev-framework) |
Changed in openobject-server: | |
importance: | Medium → Low |
importance: | Low → Wishlist |
To post a comment you must log in.
On Friday 10 September 2010, you wrote: py.diff" /bugs.launchpad .net/bugs/ 634634/ +attachment/ 1563966/ +files/ expressi
> ** Patch added: "expression.
>
> https:/
> on.py.diff
Your patch is not wrong, but it makes me wonder:
why do we have the _symbol_c and _symbol_f like that now?
Why do we default to a 0.0 float, when we could even have NULL values?
I guess, blindly changing them might break *a lot* of assumptions in modules,
but shouldn't we think of null values and also perform less conversions?