Bringing together the Apache Cassandra experts from the community and DataStax.

Want to learn? Have a question? Want to share your expertise? You are in the right place!

Not sure where to begin? Getting Started

 

question

guruprasadb avatar image
guruprasadb asked ·

Is it OK to use ALLOW FILTERING if I specify the partition key?

[FOLLOW UP QUESTION TO #10921]

Is it ok to use ALLOW FILTERING if i specify the partition key. For example i can avoid the need for creating Table 3 and use table 2 for query on subscription_id directly if i use ALLOW FILTERING on Table 2. What will be the impact again.

data modeling
10 |1000 characters needed characters left characters exceeded

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

1 Answer

Erick Ramirez avatar image
Erick Ramirez answered ·

There are very limited cases where ALLOW FILTERING is applicable for use. In most cases, it's an indication that you did model your data correctly even when restricted to rows in a single partition.

In your case, using ALLOW FILTERING on a partition with 800-900M rows is a bad idea. The performance of ALLOW FILTERING is very unpredictable even and should not be used in production. Cheers!

Share
10 |1000 characters needed characters left characters exceeded

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.