gianm opened a new pull request, #15999:
URL: https://github.com/apache/druid/pull/15999

   PR #15615 added an optimization to avoid parsing numbers twice in cases 
where we know that they should definitely be longs or definitely be doubles. 
Rather than try parsing as long first, and then try parsing as double, it would 
use only the parsing routine specific to the requested outputType.
   
   This caused a bug: previously, we would accept decimals like "1.0" or "1.23" 
as longs, by truncating them to "1". After that patch, we would treat such 
decimals as nulls when the outputType is set to LONG.
   
   This patch retains the short-circuit for doubles: if outputType is DOUBLE, 
we only parse the string as a double. But for outputType LONG, this patch 
restores the old behavior: try to parse as long first, then double.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to