Basic layout
Resource
IdResource
Name
Keyword
IdKeyword
Name
There is a many-to-many association table connecting the two.
Problem:
The keywords are used as filters. A user can select any number of keywords and it should filter the results such that each resource has ALL of the keywords selected associated (and any others not selected - the important point is that all that are selected are associated).
I can implement in PHP manipulating arrays ... but that's really slow when dealing with thousands of resources.
I essentially want to do:
QQ::In_All(QQN::Resource()->Keyword->Keyword->IdKeyword, $arrSelectedKeywords) ... something like an SQL subquery with the ALL operator such that it will “return TRUE if the comparison is TRUE for ALL of the values in the column that the subquery returns.”
Any ideas? It's probably really simple - I'm just a bit perplexed.
Thanks,
Andrew