Support Questions
Find answers, ask questions, and share your expertise

Create hive table with Ctrl-A and \N delimiter

Highlighted

Create hive table with Ctrl-A and \N delimiter

Hi,

Greeting!

I am trying to create hive external table as file format is , which on HDFS

hdfs dfs -tail /apps/hive/warehouse/hdf_stg_relation/44960050782203353079011877^A\N3079011869^A\N17^A\N2017-12-11 09:44:12^A\NGB_WS^A\NNAM^A\N^A\N1^A\N2017-12-11 09:44:12^A\N^A\N^A\N33136704^A\NY^A\NGB_WS^A\N2017-12-11 09:44:12^A\N

file delimiter by ^A\N.

i created table

CREATE EXTERNAL TABLE xyz (columns )FIELDS TERMINATED BY '\u001' 
CREATE EXTERNAL TABLE xyz (columns )FIELDS TERMINATED BY 'ASCII 001' 

First option is not working. Where as 2nd option is working but its printing \N ^ in every filed.

Any suggestion, would really appreciable.

Thanks in Advance.

Don't have an account?