loaddata

Load data into Hive with custom delimiter

隐身守侯 提交于 2019-11-27 04:53:58
问题 I'm trying to create an internal (managed) table in hive that can store my incremental log data. The table goes like this: CREATE TABLE logs (foo INT, bar STRING, created_date TIMESTAMP) ROW FORMAT DELIMITED FIELDS TERMINATED BY '<=>' STORED AS TEXTFILE; I need to load data into this table periodically. LOAD DATA INPATH '/user/foo/data/logs' INTO TABLE logs; But the data is not getting inserted into the table properly. There might be some problem with the delimiter.Can't find why. Example log