Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

split function does not work in Cloudera Impala

I keep getting an AnalysisException that says "split unknown" when I try to use the split function in Cloudera Impala. It seems to be a valid function listed on the built-in functions page. For reference, I'm using Hue to interact with Impala. Does anyone know the cause to this issue?

like image 429
Emre Colak Avatar asked May 15 '13 23:05

Emre Colak


2 Answers

The following works in Impala:

split_part(string source, string delimiter, bigint n)

Documentation is here: https://www.cloudera.com/documentation/enterprise/5-9-x/topics/impala_string_functions.html

like image 160
Timothée HENRY Avatar answered Sep 25 '22 00:09

Timothée HENRY


I asked the same question in the Google group and I was able to get an official reply. Basically, it's a misprint in the docs. split() is not supported because it would return an array and complex types are not yet supported by Impala.

like image 42
Emre Colak Avatar answered Sep 27 '22 00:09

Emre Colak