You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Aaron Ploetz (JIRA)" <ji...@apache.org> on 2014/12/29 20:33:13 UTC
[jira] [Comment Edited] (CASSANDRA-6559) cqlsh should warn about
ALLOW FILTERING
[ https://issues.apache.org/jira/browse/CASSANDRA-6559?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14260350#comment-14260350 ]
Aaron Ploetz edited comment on CASSANDRA-6559 at 12/29/14 7:33 PM:
-------------------------------------------------------------------
I have a patch (to CQLSH) ready for this one, but I wanted to get some input on the process before posting it. Here is how I have it working right now (tested with both single and multi-line queries):
{code}
aploetz@cqlsh:stackoverflow> SELECT * FROM usersbyphone WHERE username = 'wash' ALLOW FILTERING;
Use of ALLOW FILTERING detected. Are you sure you want to continue?
(Y/n) Y
phone | username | firstname | lastname
--------------+----------+-----------+-----------
111-555-1212 | wash | Hoban | Washburne
(1 rows)
aploetz@cqlsh:stackoverflow> SELECT * FROM usersbyphone WHERE username = 'wash' ALLOW
... Filtering;
Use of ALLOW FILTERING detected. Are you sure you want to continue?
(Y/n) n
ALLOW FILTERING query aborted.
aploetz@cqlsh:stackoverflow>
{code}
Right now, it requires an upper-case 'Y' to allow the query. I'm open to suggestion on exact wording and restrictions.
was (Author: aploetz):
I have a patch ready for this one, but I wanted to get some input on the process before posting it. Here is how I have it working right now (tested with both single and multi-line queries):
{code}
aploetz@cqlsh:stackoverflow> SELECT * FROM usersbyphone WHERE username = 'wash' ALLOW FILTERING;
Use of ALLOW FILTERING detected. Are you sure you want to continue?
(Y/n) Y
phone | username | firstname | lastname
--------------+----------+-----------+-----------
111-555-1212 | wash | Hoban | Washburne
(1 rows)
aploetz@cqlsh:stackoverflow> SELECT * FROM usersbyphone WHERE username = 'wash' ALLOW
... Filtering;
Use of ALLOW FILTERING detected. Are you sure you want to continue?
(Y/n) n
ALLOW FILTERING query aborted.
aploetz@cqlsh:stackoverflow>
{code}
Right now, it requires an upper-case 'Y' to allow the query. I'm open to suggestion on exact wording and restrictions.
> cqlsh should warn about ALLOW FILTERING
> ---------------------------------------
>
> Key: CASSANDRA-6559
> URL: https://issues.apache.org/jira/browse/CASSANDRA-6559
> Project: Cassandra
> Issue Type: Bug
> Components: Tools
> Reporter: Tupshin Harper
> Priority: Minor
> Labels: cqlsh
> Fix For: 2.0.12
>
>
> ALLOW FILTERING can be a convenience for preliminary exploration of your data, and can be useful for batch jobs, but it is such an anti-pattern for regular production queries, that cqlsh should provie an explicit warn ingwhenever such a query is performed.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)