tolbertam / sstable-tools

Tools for parsing, creating and doing other fun stuff with sstables
Apache License 2.0
162 stars 31 forks source link

shell mode #30

Closed tolbertam closed 8 years ago

tolbertam commented 8 years ago

it would also be nice to have an alternative command to select that behaves in the following manner:

  1. A command line mode that accepts the path to the schema, sstable(s) and the query all as files (kind of lame to make the query a file, but don't see a way around that).
  2. An interactive shell that takes the schema and sstable file as an input. The user can then make queries like 'select * from table where blah' in the interactive shell.

This could behave like a limited version of cqlsh:

Usage: cqlsh sstable [sstable...] [-s schema] [-f file]

Options:
  -s , --schema=SCHEMA       The cql schema to use for the given sstable.  If not provided, 
                             query criteria is limited to select * with no where clause.
  -f, --file=FILE            Execute commands from FILE, then exit

I think this could use the ascii table transformer like proposed in #26.

tolbertam commented 8 years ago

Done in #35