Reply
New Contributor
Posts: 3
Registered: ‎10-31-2016

Hive Query Timeout and Causing HiveServer getting hung when running wild card name search query

Hi All,

 

We are running the Hive Query  for conducting a wild card name search for a list of potential matches of customer info for one of our banking client. We are executing this query on Hue UI and this query is basically use like operation with OR condition. Query having 2K plus OR condition with like operator as mentioned below. This query compilation taking too much time and causing Hive Server Master node hung. Can you please advice if we can use any alternate approach or how we can optimize this query performance to avoid server down issue. This query runs fine in oracle DB.  

 

 Current Product

CDH-5.7.1-1.cdh5.7.1.p2008.2090

 

For Example

 

Select * from customer where partition_dt='2017-01' and full_name like 'test %'

or

full_name like ' ravi %'

or full_name like 'rajeev %'

or ....

 

..

..

 

;

 

 Current Product

CDH-5.7.1

 

Regards,

ravi

New Contributor
Posts: 3
Registered: ‎10-31-2016

Re: Hive Query Timeout and Causing HiveServer getting hung when running wild card name search query

Hi All,

 

Any help on this issue will be really helpful. Please let me know if needed any additional details.Thanks

 

Regards,

Ravindra Choyal

Highlighted
New Contributor
Posts: 3
Registered: ‎10-10-2017

Re: Hive Query Timeout and Causing HiveServer getting hung when running wild card name search query

 

try this-
Select * from customer where partition_dt='2017-01' and full_name like '%test%' limit 100;


In an alternative you can try this as well -
Select * from customer where partition_dt='2017-01'
and full_name RLIKE '*ravi*|*rajeev*'
limit 100;

Announcements