You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@calcite.apache.org by Milinda Pathirage <mp...@umail.iu.edu> on 2015/03/06 21:28:22 UTC

time to hour converison

Hi Julian,

Is expressions like 'rowtime TO HOUR' supported in 'chi' branch. I am
getting a parser error when I tried a sample query from
https://github.com/julianhyde/incubator-calcite/blob/chi/doc/STREAM.md with
latest build from 'chi' branch.

Thanks
Milinda


-- 
Milinda Pathirage

PhD Student | Research Assistant
School of Informatics and Computing | Data to Insight Center
Indiana University

twitter: milindalakmal
skype: milinda.pathirage
blog: http://milinda.pathirage.org

Re: time to hour converison

Posted by Julian Hyde <ju...@gmail.com>.
OK, the streaming changes are in.

https://github.com/apache/incubator-calcite/commit/0ecd8702ab95fd59b7ef2182720d12b2167ae968

Julian


> On Mar 7, 2015, at 9:47 AM, Milinda Pathirage <mp...@umail.iu.edu> wrote:
> 
> Hi Julian,
> 
> I am +1 for merging chi branch to master. I think its better to have
> streaming related changes in 1.1 from the point of view of Samza.
> 
> Thanks
> Milinda
> 
> On Sat, Mar 7, 2015 at 12:25 PM, Julian Hyde <ju...@hydromatic.net> wrote:
> 
>> Milinda,
>> 
>> Thanks for letting me know. The Statistic interface is a bit subtle
>> (well done for finding it). I'm still refining the stream SPI. I'll
>> make it simpler to define user-defined streams.
>> 
>> By the way: The chi branch is fairly stable right now. Do you think I
>> should merge it into master so that it can be in the 1.1 release? It
>> doesn't include streaming joins, but it does include the streaming
>> scan, filter, project, aggregate, sort. Samza-sql can build on that,
>> and can always switch back to a calcite-chi snapshot if it needs a
>> feature that isn't in the release.
>> 
>> Julian
>> 
>> On Fri, Mar 6, 2015 at 7:59 PM, Milinda Pathirage <mp...@umail.iu.edu>
>> wrote:
>>> Hi Julian,
>>> 
>>> I found the issue. It was due to the missing getStatistic implementaiton
>> in
>>> the Table returned from my table factory.
>>> 
>>> Thanks
>>> Milinda
>>> 
>>> On Fri, Mar 6, 2015 at 5:08 PM, Milinda Pathirage <mpathira@umail.iu.edu
>>> 
>>> wrote:
>>> 
>>>> Hi Julian,
>>>> 
>>>> Look like error was due to an old jar. Query went through parsing after
>>>> cleaning and rebuilding Calcite. But I am still getting
>>>> 
>>>> "Streaming aggregation requires at least one monotonic expression in
>> GROUP
>>>> BY clause".
>>>> 
>>>> Most probably this should be due to incompatibilities in my query
>> planner
>>>> code and new changes to 'chi' branch. I'll debug and see whats going on.
>>>> 
>>>> Thanks for the help.
>>>> 
>>>> Milinda
>>>> 
>>>> On Fri, Mar 6, 2015 at 3:33 PM, Julian Hyde <ju...@gmail.com>
>> wrote:
>>>> 
>>>>> We support “FLOOR(rowtime TO HOUR)”. The “TO” is part of the syntax of
>>>>> the FLOOR function, just as “AS” is part of the cast syntax “CAST(1.5
>> AS
>>>>> DOUBLE)”.
>>>>> 
>>>>> And we support the CEIL function: "CEIL(rowtime TO DAY)”.
>>>>> 
>>>>> What query did you try? Did you re-generate the parser (“mvn clean”)?
>>>>> 
>>>>> Julian
>>>>> 
>>>>> 
>>>>> On Mar 6, 2015, at 12:28 PM, Milinda Pathirage <mp...@umail.iu.edu>
>>>>> wrote:
>>>>> 
>>>>>> Hi Julian,
>>>>>> 
>>>>>> Is expressions like 'rowtime TO HOUR' supported in 'chi' branch. I am
>>>>>> getting a parser error when I tried a sample query from
>>>>>> 
>> https://github.com/julianhyde/incubator-calcite/blob/chi/doc/STREAM.md
>>>>> with
>>>>>> latest build from 'chi' branch.
>>>>>> 
>>>>>> Thanks
>>>>>> Milinda
>>>>>> 
>>>>>> 
>>>>>> --
>>>>>> Milinda Pathirage
>>>>>> 
>>>>>> PhD Student | Research Assistant
>>>>>> School of Informatics and Computing | Data to Insight Center
>>>>>> Indiana University
>>>>>> 
>>>>>> twitter: milindalakmal
>>>>>> skype: milinda.pathirage
>>>>>> blog: http://milinda.pathirage.org
>>>>> 
>>>>> 
>>>> 
>>>> 
>>>> --
>>>> Milinda Pathirage
>>>> 
>>>> PhD Student | Research Assistant
>>>> School of Informatics and Computing | Data to Insight Center
>>>> Indiana University
>>>> 
>>>> twitter: milindalakmal
>>>> skype: milinda.pathirage
>>>> blog: http://milinda.pathirage.org
>>>> 
>>> 
>>> 
>>> 
>>> --
>>> Milinda Pathirage
>>> 
>>> PhD Student | Research Assistant
>>> School of Informatics and Computing | Data to Insight Center
>>> Indiana University
>>> 
>>> twitter: milindalakmal
>>> skype: milinda.pathirage
>>> blog: http://milinda.pathirage.org
>> 
> 
> 
> 
> -- 
> Milinda Pathirage
> 
> PhD Student | Research Assistant
> School of Informatics and Computing | Data to Insight Center
> Indiana University
> 
> twitter: milindalakmal
> skype: milinda.pathirage
> blog: http://milinda.pathirage.org


Re: time to hour converison

Posted by Milinda Pathirage <mp...@umail.iu.edu>.
Hi Julian,

I am +1 for merging chi branch to master. I think its better to have
streaming related changes in 1.1 from the point of view of Samza.

Thanks
Milinda

On Sat, Mar 7, 2015 at 12:25 PM, Julian Hyde <ju...@hydromatic.net> wrote:

> Milinda,
>
> Thanks for letting me know. The Statistic interface is a bit subtle
> (well done for finding it). I'm still refining the stream SPI. I'll
> make it simpler to define user-defined streams.
>
> By the way: The chi branch is fairly stable right now. Do you think I
> should merge it into master so that it can be in the 1.1 release? It
> doesn't include streaming joins, but it does include the streaming
> scan, filter, project, aggregate, sort. Samza-sql can build on that,
> and can always switch back to a calcite-chi snapshot if it needs a
> feature that isn't in the release.
>
> Julian
>
> On Fri, Mar 6, 2015 at 7:59 PM, Milinda Pathirage <mp...@umail.iu.edu>
> wrote:
> > Hi Julian,
> >
> > I found the issue. It was due to the missing getStatistic implementaiton
> in
> > the Table returned from my table factory.
> >
> > Thanks
> > Milinda
> >
> > On Fri, Mar 6, 2015 at 5:08 PM, Milinda Pathirage <mpathira@umail.iu.edu
> >
> > wrote:
> >
> >> Hi Julian,
> >>
> >> Look like error was due to an old jar. Query went through parsing after
> >> cleaning and rebuilding Calcite. But I am still getting
> >>
> >> "Streaming aggregation requires at least one monotonic expression in
> GROUP
> >> BY clause".
> >>
> >> Most probably this should be due to incompatibilities in my query
> planner
> >> code and new changes to 'chi' branch. I'll debug and see whats going on.
> >>
> >> Thanks for the help.
> >>
> >> Milinda
> >>
> >> On Fri, Mar 6, 2015 at 3:33 PM, Julian Hyde <ju...@gmail.com>
> wrote:
> >>
> >>> We support “FLOOR(rowtime TO HOUR)”. The “TO” is part of the syntax of
> >>> the FLOOR function, just as “AS” is part of the cast syntax “CAST(1.5
> AS
> >>> DOUBLE)”.
> >>>
> >>> And we support the CEIL function: "CEIL(rowtime TO DAY)”.
> >>>
> >>> What query did you try? Did you re-generate the parser (“mvn clean”)?
> >>>
> >>> Julian
> >>>
> >>>
> >>> On Mar 6, 2015, at 12:28 PM, Milinda Pathirage <mp...@umail.iu.edu>
> >>> wrote:
> >>>
> >>> > Hi Julian,
> >>> >
> >>> > Is expressions like 'rowtime TO HOUR' supported in 'chi' branch. I am
> >>> > getting a parser error when I tried a sample query from
> >>> >
> https://github.com/julianhyde/incubator-calcite/blob/chi/doc/STREAM.md
> >>> with
> >>> > latest build from 'chi' branch.
> >>> >
> >>> > Thanks
> >>> > Milinda
> >>> >
> >>> >
> >>> > --
> >>> > Milinda Pathirage
> >>> >
> >>> > PhD Student | Research Assistant
> >>> > School of Informatics and Computing | Data to Insight Center
> >>> > Indiana University
> >>> >
> >>> > twitter: milindalakmal
> >>> > skype: milinda.pathirage
> >>> > blog: http://milinda.pathirage.org
> >>>
> >>>
> >>
> >>
> >> --
> >> Milinda Pathirage
> >>
> >> PhD Student | Research Assistant
> >> School of Informatics and Computing | Data to Insight Center
> >> Indiana University
> >>
> >> twitter: milindalakmal
> >> skype: milinda.pathirage
> >> blog: http://milinda.pathirage.org
> >>
> >
> >
> >
> > --
> > Milinda Pathirage
> >
> > PhD Student | Research Assistant
> > School of Informatics and Computing | Data to Insight Center
> > Indiana University
> >
> > twitter: milindalakmal
> > skype: milinda.pathirage
> > blog: http://milinda.pathirage.org
>



-- 
Milinda Pathirage

PhD Student | Research Assistant
School of Informatics and Computing | Data to Insight Center
Indiana University

twitter: milindalakmal
skype: milinda.pathirage
blog: http://milinda.pathirage.org

Re: time to hour converison

Posted by Julian Hyde <ju...@hydromatic.net>.
Milinda,

Thanks for letting me know. The Statistic interface is a bit subtle
(well done for finding it). I'm still refining the stream SPI. I'll
make it simpler to define user-defined streams.

By the way: The chi branch is fairly stable right now. Do you think I
should merge it into master so that it can be in the 1.1 release? It
doesn't include streaming joins, but it does include the streaming
scan, filter, project, aggregate, sort. Samza-sql can build on that,
and can always switch back to a calcite-chi snapshot if it needs a
feature that isn't in the release.

Julian

On Fri, Mar 6, 2015 at 7:59 PM, Milinda Pathirage <mp...@umail.iu.edu> wrote:
> Hi Julian,
>
> I found the issue. It was due to the missing getStatistic implementaiton in
> the Table returned from my table factory.
>
> Thanks
> Milinda
>
> On Fri, Mar 6, 2015 at 5:08 PM, Milinda Pathirage <mp...@umail.iu.edu>
> wrote:
>
>> Hi Julian,
>>
>> Look like error was due to an old jar. Query went through parsing after
>> cleaning and rebuilding Calcite. But I am still getting
>>
>> "Streaming aggregation requires at least one monotonic expression in GROUP
>> BY clause".
>>
>> Most probably this should be due to incompatibilities in my query planner
>> code and new changes to 'chi' branch. I'll debug and see whats going on.
>>
>> Thanks for the help.
>>
>> Milinda
>>
>> On Fri, Mar 6, 2015 at 3:33 PM, Julian Hyde <ju...@gmail.com> wrote:
>>
>>> We support “FLOOR(rowtime TO HOUR)”. The “TO” is part of the syntax of
>>> the FLOOR function, just as “AS” is part of the cast syntax “CAST(1.5 AS
>>> DOUBLE)”.
>>>
>>> And we support the CEIL function: "CEIL(rowtime TO DAY)”.
>>>
>>> What query did you try? Did you re-generate the parser (“mvn clean”)?
>>>
>>> Julian
>>>
>>>
>>> On Mar 6, 2015, at 12:28 PM, Milinda Pathirage <mp...@umail.iu.edu>
>>> wrote:
>>>
>>> > Hi Julian,
>>> >
>>> > Is expressions like 'rowtime TO HOUR' supported in 'chi' branch. I am
>>> > getting a parser error when I tried a sample query from
>>> > https://github.com/julianhyde/incubator-calcite/blob/chi/doc/STREAM.md
>>> with
>>> > latest build from 'chi' branch.
>>> >
>>> > Thanks
>>> > Milinda
>>> >
>>> >
>>> > --
>>> > Milinda Pathirage
>>> >
>>> > PhD Student | Research Assistant
>>> > School of Informatics and Computing | Data to Insight Center
>>> > Indiana University
>>> >
>>> > twitter: milindalakmal
>>> > skype: milinda.pathirage
>>> > blog: http://milinda.pathirage.org
>>>
>>>
>>
>>
>> --
>> Milinda Pathirage
>>
>> PhD Student | Research Assistant
>> School of Informatics and Computing | Data to Insight Center
>> Indiana University
>>
>> twitter: milindalakmal
>> skype: milinda.pathirage
>> blog: http://milinda.pathirage.org
>>
>
>
>
> --
> Milinda Pathirage
>
> PhD Student | Research Assistant
> School of Informatics and Computing | Data to Insight Center
> Indiana University
>
> twitter: milindalakmal
> skype: milinda.pathirage
> blog: http://milinda.pathirage.org

Re: time to hour converison

Posted by Milinda Pathirage <mp...@umail.iu.edu>.
Hi Julian,

I found the issue. It was due to the missing getStatistic implementaiton in
the Table returned from my table factory.

Thanks
Milinda

On Fri, Mar 6, 2015 at 5:08 PM, Milinda Pathirage <mp...@umail.iu.edu>
wrote:

> Hi Julian,
>
> Look like error was due to an old jar. Query went through parsing after
> cleaning and rebuilding Calcite. But I am still getting
>
> "Streaming aggregation requires at least one monotonic expression in GROUP
> BY clause".
>
> Most probably this should be due to incompatibilities in my query planner
> code and new changes to 'chi' branch. I'll debug and see whats going on.
>
> Thanks for the help.
>
> Milinda
>
> On Fri, Mar 6, 2015 at 3:33 PM, Julian Hyde <ju...@gmail.com> wrote:
>
>> We support “FLOOR(rowtime TO HOUR)”. The “TO” is part of the syntax of
>> the FLOOR function, just as “AS” is part of the cast syntax “CAST(1.5 AS
>> DOUBLE)”.
>>
>> And we support the CEIL function: "CEIL(rowtime TO DAY)”.
>>
>> What query did you try? Did you re-generate the parser (“mvn clean”)?
>>
>> Julian
>>
>>
>> On Mar 6, 2015, at 12:28 PM, Milinda Pathirage <mp...@umail.iu.edu>
>> wrote:
>>
>> > Hi Julian,
>> >
>> > Is expressions like 'rowtime TO HOUR' supported in 'chi' branch. I am
>> > getting a parser error when I tried a sample query from
>> > https://github.com/julianhyde/incubator-calcite/blob/chi/doc/STREAM.md
>> with
>> > latest build from 'chi' branch.
>> >
>> > Thanks
>> > Milinda
>> >
>> >
>> > --
>> > Milinda Pathirage
>> >
>> > PhD Student | Research Assistant
>> > School of Informatics and Computing | Data to Insight Center
>> > Indiana University
>> >
>> > twitter: milindalakmal
>> > skype: milinda.pathirage
>> > blog: http://milinda.pathirage.org
>>
>>
>
>
> --
> Milinda Pathirage
>
> PhD Student | Research Assistant
> School of Informatics and Computing | Data to Insight Center
> Indiana University
>
> twitter: milindalakmal
> skype: milinda.pathirage
> blog: http://milinda.pathirage.org
>



-- 
Milinda Pathirage

PhD Student | Research Assistant
School of Informatics and Computing | Data to Insight Center
Indiana University

twitter: milindalakmal
skype: milinda.pathirage
blog: http://milinda.pathirage.org

Re: time to hour converison

Posted by Milinda Pathirage <mp...@umail.iu.edu>.
Hi Julian,

Look like error was due to an old jar. Query went through parsing after
cleaning and rebuilding Calcite. But I am still getting

"Streaming aggregation requires at least one monotonic expression in GROUP
BY clause".

Most probably this should be due to incompatibilities in my query planner
code and new changes to 'chi' branch. I'll debug and see whats going on.

Thanks for the help.

Milinda

On Fri, Mar 6, 2015 at 3:33 PM, Julian Hyde <ju...@gmail.com> wrote:

> We support “FLOOR(rowtime TO HOUR)”. The “TO” is part of the syntax of the
> FLOOR function, just as “AS” is part of the cast syntax “CAST(1.5 AS
> DOUBLE)”.
>
> And we support the CEIL function: "CEIL(rowtime TO DAY)”.
>
> What query did you try? Did you re-generate the parser (“mvn clean”)?
>
> Julian
>
>
> On Mar 6, 2015, at 12:28 PM, Milinda Pathirage <mp...@umail.iu.edu>
> wrote:
>
> > Hi Julian,
> >
> > Is expressions like 'rowtime TO HOUR' supported in 'chi' branch. I am
> > getting a parser error when I tried a sample query from
> > https://github.com/julianhyde/incubator-calcite/blob/chi/doc/STREAM.md
> with
> > latest build from 'chi' branch.
> >
> > Thanks
> > Milinda
> >
> >
> > --
> > Milinda Pathirage
> >
> > PhD Student | Research Assistant
> > School of Informatics and Computing | Data to Insight Center
> > Indiana University
> >
> > twitter: milindalakmal
> > skype: milinda.pathirage
> > blog: http://milinda.pathirage.org
>
>


-- 
Milinda Pathirage

PhD Student | Research Assistant
School of Informatics and Computing | Data to Insight Center
Indiana University

twitter: milindalakmal
skype: milinda.pathirage
blog: http://milinda.pathirage.org

Re: time to hour converison

Posted by Julian Hyde <ju...@gmail.com>.
We support “FLOOR(rowtime TO HOUR)”. The “TO” is part of the syntax of the FLOOR function, just as “AS” is part of the cast syntax “CAST(1.5 AS DOUBLE)”.

And we support the CEIL function: "CEIL(rowtime TO DAY)”.

What query did you try? Did you re-generate the parser (“mvn clean”)?

Julian


On Mar 6, 2015, at 12:28 PM, Milinda Pathirage <mp...@umail.iu.edu> wrote:

> Hi Julian,
> 
> Is expressions like 'rowtime TO HOUR' supported in 'chi' branch. I am
> getting a parser error when I tried a sample query from
> https://github.com/julianhyde/incubator-calcite/blob/chi/doc/STREAM.md with
> latest build from 'chi' branch.
> 
> Thanks
> Milinda
> 
> 
> -- 
> Milinda Pathirage
> 
> PhD Student | Research Assistant
> School of Informatics and Computing | Data to Insight Center
> Indiana University
> 
> twitter: milindalakmal
> skype: milinda.pathirage
> blog: http://milinda.pathirage.org