-
Notifications
You must be signed in to change notification settings - Fork 25k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Change coerce and range query behavior #27219
Conversation
Make the "coerce" option only accepting strings, and not truncating decimal part of a floating number for BYTE, SHORT, INTEGER and LONG any more.
Since this is a community submitted pull request, a Jenkins build has not been kicked off automatically. Can an Elastic organization member please verify the contents of this patch and then kick off a build manually? |
Since this is a community submitted pull request, a Jenkins build has not been kicked off automatically. Can an Elastic organization member please verify the contents of this patch and then kick off a build manually? |
My preference is that I do agree with you that we should try to implement rounding/truncating processors as well at the same time for users who need this kind of functionality. Also for the record some disagreement was expressed on the issue regarding |
Hello @jpountz |
Pinging @elastic/es-search-aggs |
heya @jpountz I think your last comment was cut around the disagreement. What should we do with this PR? |
We discussed in FixItFriday and decided to close this pr for now. The query part should not be affected by the removal of the |
This change includes:
coerce
option currently only caststring
tonumber
, and doesn't castfloat/double
tobyte/short/integer/long
(by truncating decimal part).The "numeric range" of a range query doesn't depend on the "range" of field type (ex.
integer/long
) anymore, that means for example for a BYTE field we can do a range query on[1.5 to 200]
(equivalent to[2 to 127]
) because it also makes sense.For the option of truncate/floor/ceil/round number, we can create a new
processor
to do it ?Relates to #25861