Github user JamesRTaylor commented on a diff in the pull request:

    https://github.com/apache/phoenix/pull/67#discussion_r28370410
  
    --- Diff: phoenix-core/src/main/antlr3/PhoenixSQL.g ---
    @@ -967,9 +967,14 @@ NUMBER
         :   POSINTEGER
         ;
     
    -// Exponential format is not supported.
     DECIMAL
    --- End diff --
    
    Instead of creating a DECIMAL (which maps to PDecimal that uses a 
BigDecimal), create a rule for DOUBLE which matches the e notation and returns 
a PDouble instead (which uses a Java double). You could potentially 
conditionally return a PFloat versus a PDouble depending on the precision used, 
but not sure we really need to do that. This is the way I've seen other 
databases make it possible to define a literal that's a double instead of a 
DECIMAL or NUMERIC.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to