I use Posts and TaggedPosts column families as shown in this example
I would like to find posts tagged with 'A', 'B' and 'C' (for example)
the problem is that I have to completely read TaggedPosts with key A, and not just extract the first 10 results, as shown in the example, and then intersect with all TaggedPosts with key B, so as not to miss one, etc.
This is super inefficient, what would be your advice to do this?
I thought to change the structure of TaggedPosts: and put Posts ids as Rows and
create colmun familty TaggedPosts with ... and column_metadata=[
{column_name: tag1, ..., index_type: KEYS},
{column_name: tag2, ..., index_type: KEYS},
{column_name: tag3, ..., index_type: KEYS},
and execute:
get TaggedPosts where tag1=A and tag2=B and tag3=C;
but not sure if this will be much more efficient than client side crossing / filtering
user1125394
source
share