hive-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sadystio Ilmatunt <>
Subject Getting metadata of a SELECT statement without executing it.
Date Thu, 31 Jul 2014 22:10:18 GMT

In my company, we are working on creating hadoop-hive connector that
allows to run query on hive and import its result ( query result ).
Before we run the query on hive, we need to understand what output
schema it would generate.
Is there anyway to do that using any of hive clients ? (Thrift/JDBC etc) ?
If such feature is not available, how difficult is it to implement ?

JDBC API provides such feature. See below for information about oracle
db implementation of PreparedStatement.getMetaData(
appears hive does not implement it.
We are ok even if it is not implemented in JDBC but available through
Thrift client.

>From Oracle release notes:

PreparedStatement.getMetaData() Method
Starting from Oracle Database 11g Release 2 (11.2), JDBC drivers
support obtaining the metadata of a SELECT statement without executing
the PreparedStatement. This feature works even with the earlier
database releases. For more information, please refer to "Interface

At this link:

View raw message