title: Cassandra 3.11, Filter Results by list (searching for alternatives)
body: <p>I want to ask cassandra to filter its results by a list of arguments. But this is not possible on a &quot;normal&quot; column. Or in cassandra's words:</p>
  <pre><code>IN predicates on non-primary-key columns (access_right_id) is not yet supported
  </code></pre>
  <p>My table looks like this:</p>
  <pre><code>CREATE TABLE &quot;service&quot;
  (
      course_id       uuid,
      type            text,
      access_token    uuid,
  
      name_de         text,
      name_en         text,
      url             text,
      edit_right_id   uuid,
      access_right_id uuid,
  
      PRIMARY KEY (course_id, type, access_token)
  );
  </code></pre>
  <p>I want to execute a query like this:</p>
  <pre><code>SELECT * FROM service WHERE
  course_id = :courseId
  AND type = :type
  AND access_right_id IN :rights
  </code></pre>
  <p>I am now searching for a solution to my problem. I am thinking of three possible solutions:</p>
  <ol>
  <li>Send N times the query (maybe with a materialized view and <code>access_right_id</code> as a primary key part (clustering key))
  <pre><code>SELECT * FROM service WHERE
  course_id = :courseId
  AND type = :type
  AND access_right_id = :right
  </code></pre>
  </li>
  <li>Send a generated query like this:
  <pre><code>SELECT * FROM service WHERE
  course_id = :courseId
  AND type = :type
  AND (access_right_id = :right1 OR access_right_id = :right2 OR access_right_id = :right ...)
  </code></pre>
  </li>
  <li>Send a query without filtering and filter the result in code.</li>
  </ol>
  <p>What do you this is best in this case? What is more cassandra &quot;compliant&quot;?</p>
  <p>Thank you in advance for your input.</p>