[ 
https://issues.apache.org/jira/browse/CASSANDRA-12349?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Brandon Williams updated CASSANDRA-12349:
-----------------------------------------
    Resolution: Won't Fix
        Status: Resolved  (was: Open)

This no longer applies, so I'm closing based on Jeff's comment which I agree 
with.  If you wish to pursue this please rebase and add tests for 
consideration, and disable by default since we aren't going to change the 
default behavior this late in the game, nor rewrite all the existing cqlsh 
tests that test the restricted items.

> Adding some new features to cqlsh
> ---------------------------------
>
>                 Key: CASSANDRA-12349
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-12349
>             Project: Cassandra
>          Issue Type: New Feature
>          Components: Legacy/Tools
>         Environment: All
>            Reporter: vin01
>            Priority: Low
>              Labels: cqlsh
>
> I will like to have following features in in cqlsh, I have made a patch to 
> enable them as well.
> 1. Aliases.
> 2. Safe mode (prompt on delete,update,truncate,drop if safe_mode is true).
> 3. Press q to exit.
> Its also shared here -> 
> https://github.com/vineet01/cassandra/blob/trunk/new_features.txt
> Example for aliases :-
> cassandra@cqlsh> show 
>          ;        <enter>  ALIASES  HOST     SESSION  VERSION  
> cassandra@cqlsh> show ALIASES ;
> Aliases :> {'dk': 'desc keyspaces;', 'sl': 'select * from'}
> now if you type dk and press <tab> it will auto complete it to "desc 
> keyspace".
> Adding an alias from shell :-
> cassandra@cqlsh> alias slu=select * from login.user ;
> Alias added successfully - sle:select * login.user ;
> cassandra@cqlsh> show ALIASES ;
> Aliases :> {'slu': 'select * from login.user ;', 'dk': 'desc keyspaces;', 
> 'sl': 'select * from'}
> cassandra@cqlsh> sle
> Expanded alias to> select * from login.user ;
>  username                 | blacklisted | lastlogin | password   
> Adding an alias directly in file :-
> aliases will be kept in same cqlshrc file.
> [aliases]
> dk = desc keyspaces;
> sl = select * from
> sle = select * from login.user ;
> now if we type just "sle" it will autocomplete rest of it and show next 
> options.
> Example of safe mode :-
> cassandra@cqlsh> truncate login.user ;
> Are you sure you want to do this? (y/n) > n
> Not performing any action.
> cassandra@cqlsh> updatee login.user set password=null;
> Are you sure you want to do this? (y/n) > 
> Not performing any action.
> Initial commit :- 
> https://github.com/vineet01/cassandra/commit/0bfce2ccfc610021a74a1f82ed24aa63e1b72fec
> Current version :- 
> https://github.com/vineet01/cassandra/blob/trunk/bin/cqlsh.py
> Please review and suggest any improvements.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to