You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@hive.apache.org by Lars Francke <la...@gmail.com> on 2013/08/09 15:39:58 UTC
Problem with rank() and dense_rank()
Hi again,
CREATE TABLE test (a INT);
EXPLAIN
SELECT
DENSE_RANK() OVER (PARTITION BY a),
a
FROM test;
this minimal example fails with:
FAILED: SemanticException Failed to breakup Windowing invocations into
Groups. At least 1 group must only depend on input columns. Also check
for circular dependencies.
Underlying error:
org.apache.hadoop.hive.ql.exec.UDFArgumentTypeException: One or more
arguments are expected.
Does anyone have an idea if we're using this wrong? It is correct that
RANK() and DENSE_RANK() take a parameter (by looking at the code). I'm
not entirely sure what it does but in any case it's undocumented and
the tests seem to work without one too.
Thank you for your help.
Cheers,
Lars
Re: Problem with rank() and dense_rank()
Posted by "j.barrett Strausser" <j....@gmail.com>.
I'll do this in a bit.
There is also the issue of why Rank even accepts a param. It was never made
clear to me why this should be so.
On Fri, Aug 9, 2013 at 11:04 AM, Edward Capriolo <ed...@gmail.com>wrote:
> Please file a jira about rank being case sensitive.
>
>
> On Fri, Aug 9, 2013 at 10:26 AM, j.barrett Strausser <
> j.barrett.strausser@gmail.com> wrote:
>
>> rank is case-sensitive. Use the lower-case invocation.
>>
>> It is a rather odd error for the underlying cause and one I would have
>> never thought to check.
>>
>> I ran across the same issue you did. It was discussed in the email thread
>> I started a few weeks ago titled "Semantics of Rank".
>> I'd advise you to go look in the archives for that thread.
>>
>>
>> -barrett
>>
>>
>> On Fri, Aug 9, 2013 at 9:39 AM, Lars Francke <la...@gmail.com>wrote:
>>
>>> Hi again,
>>>
>>> CREATE TABLE test (a INT);
>>> EXPLAIN
>>> SELECT
>>> DENSE_RANK() OVER (PARTITION BY a),
>>> a
>>> FROM test;
>>>
>>> this minimal example fails with:
>>>
>>> FAILED: SemanticException Failed to breakup Windowing invocations into
>>> Groups. At least 1 group must only depend on input columns. Also check
>>> for circular dependencies.
>>> Underlying error:
>>> org.apache.hadoop.hive.ql.exec.UDFArgumentTypeException: One or more
>>> arguments are expected.
>>>
>>> Does anyone have an idea if we're using this wrong? It is correct that
>>> RANK() and DENSE_RANK() take a parameter (by looking at the code). I'm
>>> not entirely sure what it does but in any case it's undocumented and
>>> the tests seem to work without one too.
>>>
>>> Thank you for your help.
>>>
>>> Cheers,
>>> Lars
>>>
>>
>>
>>
>> --
>>
>>
>> https://github.com/bearrito
>> @deepbearrito
>>
>
>
--
https://github.com/bearrito
@deepbearrito
Re: Problem with rank() and dense_rank()
Posted by Edward Capriolo <ed...@gmail.com>.
Please file a jira about rank being case sensitive.
On Fri, Aug 9, 2013 at 10:26 AM, j.barrett Strausser <
j.barrett.strausser@gmail.com> wrote:
> rank is case-sensitive. Use the lower-case invocation.
>
> It is a rather odd error for the underlying cause and one I would have
> never thought to check.
>
> I ran across the same issue you did. It was discussed in the email thread
> I started a few weeks ago titled "Semantics of Rank".
> I'd advise you to go look in the archives for that thread.
>
>
> -barrett
>
>
> On Fri, Aug 9, 2013 at 9:39 AM, Lars Francke <la...@gmail.com>wrote:
>
>> Hi again,
>>
>> CREATE TABLE test (a INT);
>> EXPLAIN
>> SELECT
>> DENSE_RANK() OVER (PARTITION BY a),
>> a
>> FROM test;
>>
>> this minimal example fails with:
>>
>> FAILED: SemanticException Failed to breakup Windowing invocations into
>> Groups. At least 1 group must only depend on input columns. Also check
>> for circular dependencies.
>> Underlying error:
>> org.apache.hadoop.hive.ql.exec.UDFArgumentTypeException: One or more
>> arguments are expected.
>>
>> Does anyone have an idea if we're using this wrong? It is correct that
>> RANK() and DENSE_RANK() take a parameter (by looking at the code). I'm
>> not entirely sure what it does but in any case it's undocumented and
>> the tests seem to work without one too.
>>
>> Thank you for your help.
>>
>> Cheers,
>> Lars
>>
>
>
>
> --
>
>
> https://github.com/bearrito
> @deepbearrito
>
Re: Problem with rank() and dense_rank()
Posted by "j.barrett Strausser" <j....@gmail.com>.
https://issues.apache.org/jira/browse/HIVE-5038
On Fri, Aug 9, 2013 at 11:44 AM, Lars Francke <la...@gmail.com>wrote:
> Thank you very much guys for the response.
>
> I saw your thread but I must have totally missed your resolution of
> the issue. Sorry for the "repost".
>
> I'd be happy to file an issue as well.
>
> Cheers,
> Lars
>
> On Fri, Aug 9, 2013 at 4:26 PM, j.barrett Strausser
> <j....@gmail.com> wrote:
> > rank is case-sensitive. Use the lower-case invocation.
> >
> > It is a rather odd error for the underlying cause and one I would have
> never
> > thought to check.
> >
> > I ran across the same issue you did. It was discussed in the email
> thread I
> > started a few weeks ago titled "Semantics of Rank".
> > I'd advise you to go look in the archives for that thread.
> >
> >
> > -barrett
> >
> >
> > On Fri, Aug 9, 2013 at 9:39 AM, Lars Francke <la...@gmail.com>
> wrote:
> >>
> >> Hi again,
> >>
> >> CREATE TABLE test (a INT);
> >> EXPLAIN
> >> SELECT
> >> DENSE_RANK() OVER (PARTITION BY a),
> >> a
> >> FROM test;
> >>
> >> this minimal example fails with:
> >>
> >> FAILED: SemanticException Failed to breakup Windowing invocations into
> >> Groups. At least 1 group must only depend on input columns. Also check
> >> for circular dependencies.
> >> Underlying error:
> >> org.apache.hadoop.hive.ql.exec.UDFArgumentTypeException: One or more
> >> arguments are expected.
> >>
> >> Does anyone have an idea if we're using this wrong? It is correct that
> >> RANK() and DENSE_RANK() take a parameter (by looking at the code). I'm
> >> not entirely sure what it does but in any case it's undocumented and
> >> the tests seem to work without one too.
> >>
> >> Thank you for your help.
> >>
> >> Cheers,
> >> Lars
> >
> >
> >
> >
> > --
> >
> >
> > https://github.com/bearrito
> > @deepbearrito
>
--
https://github.com/bearrito
@deepbearrito
Re: Problem with rank() and dense_rank()
Posted by Lars Francke <la...@gmail.com>.
Thank you very much guys for the response.
I saw your thread but I must have totally missed your resolution of
the issue. Sorry for the "repost".
I'd be happy to file an issue as well.
Cheers,
Lars
On Fri, Aug 9, 2013 at 4:26 PM, j.barrett Strausser
<j....@gmail.com> wrote:
> rank is case-sensitive. Use the lower-case invocation.
>
> It is a rather odd error for the underlying cause and one I would have never
> thought to check.
>
> I ran across the same issue you did. It was discussed in the email thread I
> started a few weeks ago titled "Semantics of Rank".
> I'd advise you to go look in the archives for that thread.
>
>
> -barrett
>
>
> On Fri, Aug 9, 2013 at 9:39 AM, Lars Francke <la...@gmail.com> wrote:
>>
>> Hi again,
>>
>> CREATE TABLE test (a INT);
>> EXPLAIN
>> SELECT
>> DENSE_RANK() OVER (PARTITION BY a),
>> a
>> FROM test;
>>
>> this minimal example fails with:
>>
>> FAILED: SemanticException Failed to breakup Windowing invocations into
>> Groups. At least 1 group must only depend on input columns. Also check
>> for circular dependencies.
>> Underlying error:
>> org.apache.hadoop.hive.ql.exec.UDFArgumentTypeException: One or more
>> arguments are expected.
>>
>> Does anyone have an idea if we're using this wrong? It is correct that
>> RANK() and DENSE_RANK() take a parameter (by looking at the code). I'm
>> not entirely sure what it does but in any case it's undocumented and
>> the tests seem to work without one too.
>>
>> Thank you for your help.
>>
>> Cheers,
>> Lars
>
>
>
>
> --
>
>
> https://github.com/bearrito
> @deepbearrito
Re: Problem with rank() and dense_rank()
Posted by "j.barrett Strausser" <j....@gmail.com>.
rank is case-sensitive. Use the lower-case invocation.
It is a rather odd error for the underlying cause and one I would have
never thought to check.
I ran across the same issue you did. It was discussed in the email thread I
started a few weeks ago titled "Semantics of Rank".
I'd advise you to go look in the archives for that thread.
-barrett
On Fri, Aug 9, 2013 at 9:39 AM, Lars Francke <la...@gmail.com> wrote:
> Hi again,
>
> CREATE TABLE test (a INT);
> EXPLAIN
> SELECT
> DENSE_RANK() OVER (PARTITION BY a),
> a
> FROM test;
>
> this minimal example fails with:
>
> FAILED: SemanticException Failed to breakup Windowing invocations into
> Groups. At least 1 group must only depend on input columns. Also check
> for circular dependencies.
> Underlying error:
> org.apache.hadoop.hive.ql.exec.UDFArgumentTypeException: One or more
> arguments are expected.
>
> Does anyone have an idea if we're using this wrong? It is correct that
> RANK() and DENSE_RANK() take a parameter (by looking at the code). I'm
> not entirely sure what it does but in any case it's undocumented and
> the tests seem to work without one too.
>
> Thank you for your help.
>
> Cheers,
> Lars
>
--
https://github.com/bearrito
@deepbearrito