Reply
HJ
Explorer
Posts: 12
Registered: ‎07-05-2018
Accepted Solution

impala-shell

i am trying to translate the query which is in sql working on oracle.

the query goes like this,

select MAX(NANVL(Column name,0)) OVER (partition by x, y) as z from table name 

  I would like to do the same using impala-shell on kudu-table because when i performed i got the following exception


ERROR: AnalysisException: default.nanvl() unknown
Thanks in advance

Posts: 512
Topics: 14
Kudos: 85
Solutions: 45
Registered: ‎09-02-2016

Re: impala-shell

@HJ

 

Not sure which version of impala, CDH you are using

 

NANVL in-build function is available in oracle but impala does not support (as of CDH 5.14 version)

 

Below is the link for CDH 5.14 shows all the available conditional functions, which has NVL, NVL2 but not NANVL. You may need to write your custom function to meet this part

 

https://www.cloudera.com/documentation/enterprise/5-14-x/topics/impala_conditional_functions.html

 

 

Highlighted
HJ
Explorer
Posts: 12
Registered: ‎07-05-2018

Re: impala-shell

thank you for the solution, i have a sql query which has group by roll up clause and it goes like following.

from tablename group by rollup(decode(-----some expression here-----),decode(some expression here),decode (some expression here))

as i said i have to modify the query where the query work on kudu using impala shell,

when i performed the query i got the follwing exception,

 

ERROR: AnalysisException: default.rollup() unknown

 

please help me with what has to be done in this case

 

thank you 

Announcements