Member since
06-18-2022
1
Post
0
Kudos Received
0
Solutions
06-18-2022
09:22 AM
I have a problems inserting data in a hive table, i'm using Amazon JDBC (AmazonHiveJDBC-2.6.19.1022), I test with Cloudera JDBS too. create table sf1 (c1 string, c2 string, c3 string, c4 string, c5 string, c6 string, c7 string); Then i try to insert into that table (using any GUI, ex. DBvisualizer) data as follows insert into sf1 (c1,c2,c3,c4,c5,c6,c7) values ('1','2','3','4','5','6','7') but i get: ERROR: Code:40000, Sql State: 42000 error while compiling statement: FAILED: SemanticException 0:0 Expected 7 columns for insclause-0/default@sf1; select produces 1 columns. Error encountered near token "7" [Code 40000, SQL State: 42000][...Expected 7 columns ...; select produces 1 columns. Error encounterednear token "7"] I have no problem inserting with the same clause using hive command line.
... View more
Labels:
- Labels:
-
Apache Hadoop
-
Apache Hive