Example: a field data is: I, I eat, I went to sleep,,
B field data for:
HiveQL: select/* + mapjoin (test1) */test1. B, test2. A from test1 join test2 where test1. Like a '%' + test2. B + '%';
Above this is not I want, so I tried it in several other functions:
Where find_in_set (test1. B, test2. A) & gt; 0
Where the locate (test2. A, test1. B, 0) & gt; 0
Where instr (test2. A, test1. B) & gt; 0
All the above several ways to check out what I want results in (a "I ate"), according to the logic, these methods should be,
So you know why?
Have any Suggestions?
CodePudding user response:
Well, for a long time, I answer by oneself, maybe not quite right, but is, indeed, I measured,,,When using mapjoin, small table data in the first row will not be as a filter conditions,,,, don't know whether I Hive bugs, can only for our table happens!
My solution is that, the first line of the small table, add a row casually,,,
OK,,, solved,