Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

Temporary table not found (ODBC driver issue ?)

Solved Go to solution
Highlighted

Temporary table not found (ODBC driver issue ?)

Explorer

Hi,

I am facing the following problem : Using the Hortonworks ODBC driver for Hive, I can create a temporary table (hiveserver2.log tell me that it is done without error), but I can't retrieve this table with a SELECT query thereafter.

When I try to do so, I get a "table not found" error. Does it mean the ODBC driver does not keep the session between 2 hive calls ? Is there something I am doing wrong or some configuration I need to set ? I believe since hive 0.14, the "temporary table" part in the ODBC driver configuration is not necessary, or is it ?

Thanks in advance,

Sylvain.

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted

Re: Temporary table not found (ODBC driver issue ?)

Contributor

@dvt isoft I am not sure which client you are using to connect. It might be worth checking if the same connection (so that same session) is being used to run successive queries or is it like client is kind of establishing new connection for each query. Otherwise, hive odbc driver is able to run select queries on temporary tables and as you already mentioned you don't need to enable it explicitly starting Hive 0.14.

View solution in original post

11 REPLIES 11
Highlighted

Re: Temporary table not found (ODBC driver issue ?)

Expert Contributor

@dvt isoft Hi,

Are you able to access hive through command line? If so, I would look to see if your table is showing up there. I would also double check the database is selected correctly. Are you creating it in default database or creating your own database and a table within it.

Thanks

Highlighted

Re: Temporary table not found (ODBC driver issue ?)

Explorer

Thank you mliem,

I am able to access hive through beeline. I can create my temporary table, and see it appearing with a "show tables" command using beeline.

I tried creating my temporary table in the default database, and in a specified one, but I get the same result.

Sylvain.

Highlighted

Re: Temporary table not found (ODBC driver issue ?)

Expert Contributor

@dvt isoft Are the tables you've created via ODBC showing up in beeline? What about if you try creating a database instead.

Highlighted

Re: Temporary table not found (ODBC driver issue ?)

Explorer

Yes, the tables created via ODBC are showing up in beeline. Creating a database via ODBC works too. The problem seems to be only appearing with temporary tables.

Highlighted

Re: Temporary table not found (ODBC driver issue ?)

Expert Contributor

Also, is the cluster kerberized? Do you have ranger policies for Hive?

Highlighted

Re: Temporary table not found (ODBC driver issue ?)

Explorer

My cluster is not kerberized and I do not have ranger policies for Hive.

Highlighted

Re: Temporary table not found (ODBC driver issue ?)

Contributor

@dvt isoft I am not sure which client you are using to connect. It might be worth checking if the same connection (so that same session) is being used to run successive queries or is it like client is kind of establishing new connection for each query. Otherwise, hive odbc driver is able to run select queries on temporary tables and as you already mentioned you don't need to enable it explicitly starting Hive 0.14.

View solution in original post

Highlighted

Re: Temporary table not found (ODBC driver issue ?)

Explorer

Thank you.

As you said, the client I am using is generating a new session at each call, that was the problem.

Sylvain.

Re: Temporary table not found (ODBC driver issue ?)

@dvt isoft

Are you able to connect hive using ODBC driver? Can you add screen shot?

Can you add screen shot for successful table creation?

run show tables and add screen shot as well. Thanks

Don't have an account?
Coming from Hortonworks? Activate your account here