You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@hive.apache.org by Mich Talebzadeh <mi...@gmail.com> on 2018/05/10 17:44:24 UTC

Cannot send metadata info from Hive 2.0.1 to Hive metastore on Oracle 12c

Hi,

Running Hive 2.0.1 on Oracle 12c, it seems that Hive cannot perform insert
metadata info into metadata table "HIVEUSER"."TBLS"

When I try to create a simple table in Hive. It sends null values to Oracle
metastore.

0: jdbc:hive2://rhes564:10099/default> use test2;

0: jdbc:hive2://rhes564:10099/default> create table michboy(col1 int, col2
varchar(30));

ERROR : FAILED: Execution Error, return code 1 from
org.apache.hadoop.hive.ql.exec.DDLTask.
MetaException(message:javax.jdo.JDODataStoreException: Insert of object
"org.apache.hadoop.hive.metastore.model.MTable@6b511a66" using statement
"INSERT INTO TBLS
*(TBL_ID,CREATE_TIME,DB_ID,LAST_ACCESS_TIME,OWNER,RETENTION,SD_ID,TBL_NAME,TBL_TYPE,VIEW_EXPANDED_TEXT,VIEW_ORIGINAL_TEXT)
VALUES (?,?,?,?,?,?,?,?,?,?,?)" failed : ORA-01400: cannot insert NULL into
("HIVEUSER"."TBLS"."IS_REWRITE_ENABLED")*

java.sql.SQLIntegrityConstraintViolationException: ORA-01400: cannot insert
NULL into ("HIVEUSER"."TBLS"."IS_REWRITE_ENABLED")

Any ideas what can cause this?

The version of Hive in Oracle hive metadata is:

select * from version;
VER_ID, SCHEMA_VERSION, VERSION_COMMENT
1       2.0.0           Hive release version 2.0.0

Thanks


Dr Mich Talebzadeh



LinkedIn * https://www.linkedin.com/profile/view?id=AAEAAAAWh2gBxianrbJd6zP6AcPCCdOABUrV8Pw
<https://www.linkedin.com/profile/view?id=AAEAAAAWh2gBxianrbJd6zP6AcPCCdOABUrV8Pw>*



http://talebzadehmich.wordpress.com


*Disclaimer:* Use it at your own risk. Any and all responsibility for any
loss, damage or destruction of data or any other property which may arise
from relying on this email's technical content is explicitly disclaimed.
The author will in no case be liable for any monetary damages arising from
such loss, damage or destruction.

Re: Cannot send metadata info from Hive 2.0.1 to Hive metastore on Oracle 12c

Posted by Mich Talebzadeh <mi...@gmail.com>.
upgraded from hive 2.0.1 to hive 2.3.2 and it works now!

0: jdbc:hive2://rhes564:10099/default> create table abc(col1 int);
No rows affected (1.21 seconds)
0: jdbc:hive2://rhes564:10099/default> desc abc;
+-----------+------------+----------+
| col_name  | data_type  | comment  |
+-----------+------------+----------+
| col1      | int        |          |
+-----------+------------+----------+
1 row selected (0.147 seconds)

Dr Mich Talebzadeh



LinkedIn * https://www.linkedin.com/profile/view?id=AAEAAAAWh2gBxianrbJd6zP6AcPCCdOABUrV8Pw
<https://www.linkedin.com/profile/view?id=AAEAAAAWh2gBxianrbJd6zP6AcPCCdOABUrV8Pw>*



http://talebzadehmich.wordpress.com


*Disclaimer:* Use it at your own risk. Any and all responsibility for any
loss, damage or destruction of data or any other property which may arise
from relying on this email's technical content is explicitly disclaimed.
The author will in no case be liable for any monetary damages arising from
such loss, damage or destruction.



On 10 May 2018 at 18:44, Mich Talebzadeh <mi...@gmail.com> wrote:

> Hi,
>
> Running Hive 2.0.1 on Oracle 12c, it seems that Hive cannot perform insert
> metadata info into metadata table "HIVEUSER"."TBLS"
>
> When I try to create a simple table in Hive. It sends null values to
> Oracle metastore.
>
> 0: jdbc:hive2://rhes564:10099/default> use test2;
>
> 0: jdbc:hive2://rhes564:10099/default> create table michboy(col1 int,
> col2 varchar(30));
>
> ERROR : FAILED: Execution Error, return code 1 from
> org.apache.hadoop.hive.ql.exec.DDLTask. MetaException(message:javax.jdo.JDODataStoreException:
> Insert of object "org.apache.hadoop.hive.metastore.model.MTable@6b511a66"
> using statement "INSERT INTO TBLS
> *(TBL_ID,CREATE_TIME,DB_ID,LAST_ACCESS_TIME,OWNER,RETENTION,SD_ID,TBL_NAME,TBL_TYPE,VIEW_EXPANDED_TEXT,VIEW_ORIGINAL_TEXT)
> VALUES (?,?,?,?,?,?,?,?,?,?,?)" failed : ORA-01400: cannot insert NULL into
> ("HIVEUSER"."TBLS"."IS_REWRITE_ENABLED")*
>
> java.sql.SQLIntegrityConstraintViolationException: ORA-01400: cannot
> insert NULL into ("HIVEUSER"."TBLS"."IS_REWRITE_ENABLED")
>
> Any ideas what can cause this?
>
> The version of Hive in Oracle hive metadata is:
>
> select * from version;
> VER_ID, SCHEMA_VERSION, VERSION_COMMENT
> 1       2.0.0           Hive release version 2.0.0
>
> Thanks
>
>
> Dr Mich Talebzadeh
>
>
>
> LinkedIn * https://www.linkedin.com/profile/view?id=AAEAAAAWh2gBxianrbJd6zP6AcPCCdOABUrV8Pw
> <https://www.linkedin.com/profile/view?id=AAEAAAAWh2gBxianrbJd6zP6AcPCCdOABUrV8Pw>*
>
>
>
> http://talebzadehmich.wordpress.com
>
>
> *Disclaimer:* Use it at your own risk. Any and all responsibility for any
> loss, damage or destruction of data or any other property which may arise
> from relying on this email's technical content is explicitly disclaimed.
> The author will in no case be liable for any monetary damages arising from
> such loss, damage or destruction.
>
>
>
>
>