Created 02-09-2017 12:27 PM
I am trying to connect hive non exist database using jdbc url . It does not throw any error and it is connecting with default database which should not be. This issue is occurring for hive-jdbc-1.2.1. if we use version hive-jdbc-0.12.0-cdh5.1.2 then we are getting proper exception showing Database does not exist. I am using HDP 2.4.2 and Hive 1.2.1.2.4 . I do not want to use cloudera jar. My code snapshot is given below where "acb" is unknown database.
Class.forName("org.apache.hive.jdbc.HiveDriver"); conn = DriverManager.getConnection("jdbc:hive2://*****.***.***:10000/acb");
Is it bug for hive jdbc driver ? Please help to fix this issue asap.
Created 02-09-2017 02:18 PM
Can you try connecting to another database which actually exists. Does that work? There was a known issue in Hive JDBC which was fixed in hive 0.13 but it was ignoring any database regardless. Check the following if this applies to you.
Created 02-09-2017 02:25 PM
Thanks for your reply . This is working for existing database. But we are facing this issue for non existing database . Looks like issue is not resolved yet.