drill-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Venkata krishnan Sowrirajan" <vsowrira...@maprtech.com>
Subject Re: Review Request 28496: DRILL-1779: Add unix_timestamp function
Date Mon, 01 Dec 2014 18:45:56 GMT


> On Nov. 29, 2014, 2:58 a.m., Kannan Rajah wrote:
> > exec/java-exec/src/main/java/org/apache/drill/exec/expr/fn/impl/DateTypeFunctions.java,
line 484
> > <https://reviews.apache.org/r/28496/diff/2/?file=777319#file777319line484>
> >
> >     Why we do need to create formatter when it is not used? Please take a look at
this commit for the fix that I had made. It is returning milliseconds by mistake, so ignore
that part.

Yeah, you are right. This is not required here. Copy/paste mistake.


> On Nov. 29, 2014, 2:58 a.m., Kannan Rajah wrote:
> > exec/java-exec/src/main/java/org/apache/drill/exec/expr/fn/impl/DateTypeFunctions.java,
line 508
> > <https://reviews.apache.org/r/28496/diff/2/?file=777319#file777319line508>
> >
> >     Curious to know how we will hit this case since we have an overloaded function
that does not take any args.

Yeah, this is also not required, I think. As we will not hit this condition for the reason
you mentioned above.


> On Nov. 29, 2014, 2:58 a.m., Kannan Rajah wrote:
> > exec/java-exec/src/main/java/org/apache/drill/exec/expr/fn/impl/DateTypeFunctions.java,
line 489
> > <https://reviews.apache.org/r/28496/diff/2/?file=777319#file777319line489>
> >
> >     Can we not just use the queryStartDate instead of creating a new date instance?

If I am not wrong, is this the fragment's queryStartTime("incoming.getContext().getQueryStartTime()")?
Like this instead of creating an instance of Date.


- Venkata krishnan


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/28496/#review63276
-----------------------------------------------------------


On Nov. 27, 2014, 8:16 a.m., Venkata krishnan Sowrirajan wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/28496/
> -----------------------------------------------------------
> 
> (Updated Nov. 27, 2014, 8:16 a.m.)
> 
> 
> Review request for drill and Mehant Baid.
> 
> 
> Repository: drill-git
> 
> 
> Description
> -------
> 
> Added functionality for unix_timestamp() similar to MySQL
> 
> 
> Diffs
> -----
> 
>   exec/java-exec/src/main/java/org/apache/drill/exec/expr/fn/impl/DateTypeFunctions.java
f063466 
>   exec/java-exec/src/test/java/org/apache/drill/exec/fn/impl/TestDateFunctions.java 1ecae19

>   exec/java-exec/src/test/resources/functions/date/to_unixtimestamp_for_date.json PRE-CREATION

>   exec/java-exec/src/test/resources/functions/date/to_unixtimestamp_for_date_with_pattern.json
PRE-CREATION 
> 
> Diff: https://reviews.apache.org/r/28496/diff/
> 
> 
> Testing
> -------
> 
> Added testcases
> 
> 
> Thanks,
> 
> Venkata krishnan Sowrirajan
> 
>


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message