I am using HDP 2.5 in hortonworks sanbox. The HIVE version is 1.2.1. I am trying to create hive table with primary key constraint with below query:
CREATE TABLE pk
(id1 int,id2 int,
PARTITIONED BY (year string);
while executing this create table query it throws below error:
ParseException line 1:65 cannot recognize input near 'key' '(' 'id1' in column type
I am not getting what this error and how to resolve it.
Is constraints supported in HIVE 1.2.1 ?
can anyone help me out to resolve this issue ?