1
votes

select * from cancel where deduction_percentage like '%100% cancellation charge%';

SemanticException [Error 10014]: Line 1:27 Wrong arguments ''%100% cancellation charge%'': No matching method for class org.apache.hadoop.hive.ql.udf.UDFLike with (array, string). Possible choices: FUNC(string, string)

1
The exception says that deduction_percentage is an Array. like works with strings. Concatenate array using concat_wsor use array_contains(Array, value) function. Or compare array element using[] - leftjoin

1 Answers

1
votes

Your deduction_percentage seems like array datatype. The query you written will work for string datatype fields only.

select * from cancel where concat_ws(',',deduction_percentage) like '%100% cancellation charge%';