Ben Chuanlong Du's Blog

It is never too late to learn.

Use Hive in Zeppelin

Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!

Configuration

It seems that you have set a queue using the following code even if you have already set a queue in properties.

%hive-interpreter

set mapred.job.queue.name = your_queue;
set mapred.min.split.size = 65536;
set mapred.max.split.size = 268435456;

Tricks & Traps

  1. When you write a query in Hive shell, you should end it with a semicolon (;).

    load data local inpath '/tmp/sql.txt' into table files;
    

    However, you should never end a SQL statement with a semicolon (;) in Zeppelin.

    load data local inpath '/tmp/sql.txt' into table files
    

    For this reason, you cannot run multiple SQL statements in a cell in Zeppelin. You should split different SQL statements into different cells.

Comments