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

James Taylor commented on PHOENIX-1485:
---------------------------------------

Thanks for the patch, [~gabriel.reid]. As far as the change you made to 
FunctionParseNode, I don't think it's correct. The required number of 
parameters for a function is the number of parameters that don't have default 
values (the requiredArgCount < i part of the if isn't necessary either, but 
it's not hurting anything). Once you declare a default value for a parameter, 
all following parameters much also have default values. By default, if any of 
the required parameters are null, a function evaluates to null. This can be 
overridden through the following FunctionParseNodeFunction:
{code}
    /**
     * Determines whether or not we can collapse a function expression to null 
if a required
     * parameter is null.
     * @param context
     * @param index index of parameter
     * @return true if when the parameter at index is null, the function always 
evaluates to null
     *  and false otherwise.
     * @throws SQLException
     */
    public boolean evalToNullIfParamIsNull(StatementContext context, int index) 
throws SQLException {
        return true;
    }
{code}

What problem are you running into without that code change?

> Date columns should be displayed without timezone offset
> --------------------------------------------------------
>
>                 Key: PHOENIX-1485
>                 URL: https://issues.apache.org/jira/browse/PHOENIX-1485
>             Project: Phoenix
>          Issue Type: Bug
>    Affects Versions: 4.1
>            Reporter: noam bulvik
>         Attachments: PHOENIX-1485.patch
>
>
> when date or timestamp  column queried the value is the date with timezone 
> offset. this is not how it is handled by other jdbc drivers like oracle and 
> impala. and it seems strange that when I have text file with specific date 
> and I use bulk loader to store it , when I will use select * .. I will get 
> different dates then the one in the file (because  of the time zone offset)
> by default the date should be displayed without any offset.
> it will be nice to have an option to add the timezone offset the option in 
> the driver 



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

Reply via email to