After studying my field mappings and bridges and a whole host of other elaborate Hibernate Search topics, I came to discover that it was indeed something silly. Very silly.
See if you can catch the error from excerpts from my previous messages:
Code:
On the Search tab in Luke, I apply the same query, and I get all the right hits. What is curious perhaps is that there are columns for _hibernate_class, keyWords.id, keyWords.name among others, but the keyWords.name column is empty while the keyWords.id column is populated with space-delimited IDs from the KEY_WORD table.
And this one:
Code:
But my tests with +keywords.name:Aluminum~0.4 return zip.
Can you see the problem?
If you can't, then I might feel a bit better. The issue is my spelling in the query. Where Luke was correctly using key
Words.name, I was using keywords.name with no capital W.
So yes, I am an idiot.
It just goes to show that even the simplest, most innocent things must not be overlooked.
A less obvious lesson learned here is that M:M searches are quite easy by declaring the recipient of the association the usual way and by annotating it on the owning class with @IndexedEmbedded.
Thanks to everyone for their help.