I'm trying to create a partitioned table using dynamic partitioning, but i'm facing an issue. I'm running Hive 0.12 on Hortonworks Sandbox 2.0.
set hive.exec.dynamic.partition=true;
INSERT OVERWRITE TABLE demo_tab PARTITION (land)
SELECT stadt, geograph_breite, id, t.country
FROM demo_stg t;
however it does not work.. I'm getting an Error.
Here is the Query to create the table demo_stg:
create table demo_stg
(
country STRING,
stadt STRING,
geograph_breite FLOAT,
id INT
)
ROW FORMAT DELIMITED FIELDS TERMINATED BY "\073";
And demo_tab:
CREATE TABLE demo_tab
(
stadt STRING,
geograph_breite FLOAT,
id INT
)
PARTITIONED BY (land STRING)
ROW FORMAT DELIMITED FIELDS TERMINATED BY "\073";
- The table demo_stg is also filled with data, so it's not empty.
Thanks for help :)