Beruflich Dokumente
Kultur Dokumente
# =============================================
start hive
Hive database and environment management commands
# =============================================
show databases;
show databases;
SHOW DATABASES;
use practice_db1;
set hive.cli.print.current.db=true;
# ==========================================================
# 1.check hive/warehouse/practice_db1/sample......
# access_log file available ?
CREATE TABLE emp(eid INT, ename STRING , esal FLOAT , did INT)
ROW FORMAT DELIMITED
FIELDS TERMINATED BY ',' ;
# ==========================================================
SELECT name
FROM EMPLOYEE
WHERE ARRAY_CONTAINS(subordinate, 'Mary Smith') = true;
# Display array like a table
set hive.exec.dynamic.partition.mode=nonstrict;
# Query on partitioned table observe the time required, plus it doesnt even go to MR for
execution