Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

User defined sql query in tHiveInput component not working

Hi,
I am trying to mention a min() function where clause (sub query) in one of my 'tHiveInput' component as below:-
"select 
agents_updates.col1,

agents_updates.col2
FROM tl.agents_updates
WHERE agents_updates.loadtime = (Select min(t2.loadtime) from tl.agents_updates t2)"
I am getting below error any suggestions please:-
connecting to socket on port 3630
connected
Exception in component tHiveInput_3
java.sql.SQLException: Error while processing statement: FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.mr.MapRedTask
at org.apache.hive.jdbc.HiveStatement.execute(HiveStatement.java:296)
at org.apache.hive.jdbc.HiveStatement.executeQuery(HiveStatement.java:392)
at bi_poc_mi.j1000_stg_agency_diff_lake_to_vault_min_wip_0_1.J1000_Stg_Agency_Diff_Lake_To_Vault_Min_WIP.tHiveInput_3Process(J1000_Stg_Agency_Diff_Lake_To_Vault_Min_WIP.java:4986)
at bi_poc_mi.j1000_stg_agency_diff_lake_to_vault_min_wip_0_1.J1000_Stg_Agency_Diff_Lake_To_Vault_Min_WIP.runJobInTOS(J1000_Stg_Agency_Diff_Lake_To_Vault_Min_WIP.java:8097)
at bi_poc_mi.j1000_stg_agency_diff_lake_to_vault_min_wip_0_1.J1000_Stg_Agency_Diff_Lake_To_Vault_Min_WIP.main(J1000_Stg_Agency_Diff_Lake_To_Vault_Min_WIP.java:7942)
Labels (4)
4 Replies
Anonymous
Not applicable
Author

Hi,
Is your defined sql query working  well on your hive cluster without using thiveinput component? On which build version you got this issue?
Best regards
Sabrina
Anonymous
Not applicable
Author

Hi Sabrina,
Thanks for the reply and apologies for the late response.Yes the queries are working in HQL editor (like HUE) but not working tHiveinput componet.I am using TalendOpenStudio6.1 for Bigdata edition.
Cheers,
Anonymous
Not applicable
Author

avez vous une idée sur cette erreur

Error while processing statement: FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.tez.TezTask

Anonymous
Not applicable
Author

Hello,

What's does your sql query look like? Are you using ‘Where' clause in the query? Does it work if you remove the clause?

Best regards

Sabrina