[ 
https://issues.apache.org/jira/browse/PHOENIX-1030?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14134776#comment-14134776
 ] 

James Taylor commented on PHOENIX-1030:
---------------------------------------

bq. I also modified CurrentDateTimeFunction to return PER_STATEMENT for the 
DeterministicEnum. I had to change readFields and write in LiteralExpression 
because of the new DeterministicEnum (which I encoded in an int).

This is fine as long as you handle the case of an old client talking to a new 
server (where your new byte value for the enum wouldn't be sent).

For the possible values of your Determinism enum, can you think of a case where 
it'd be NEVER? I know for NEXT VALUE FOR, multiple occurrences always bind to 
the same value. Not sure about RAND.

> Change Expression.isDeterministic() to return an ENUM with three values 
> {DETERMINISTIC, UNDETERMINISTIC_ROW, UNDETERMINISTIC_STMT}
> ----------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: PHOENIX-1030
>                 URL: https://issues.apache.org/jira/browse/PHOENIX-1030
>             Project: Phoenix
>          Issue Type: Improvement
>            Reporter: Thomas D'Silva
>            Assignee: Thomas D'Silva
>         Attachments: PHOENIX-1030-3.0.patch, PHOENIX-1030-master.patch
>
>
> Change Expression.isDeterministic() to return an ENUM with three values
> DETERMINISTIC -  the expression returns the same output every time given the 
> same input.
> UNDETERMINISTIC_ROW - the expression should be computed for every row
> UNDETERMINISTIC_STMT - the expression should be be computed for a given 
> statement only once
> See PHOENIX-1001



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to