How to clear all data using CQL?

2014-04-16 Thread Sebastian Schmidt
Hey I want to do unit tests for software that uses Cassandra as storage backend. Using the Hector client, I could just iterate over all keyspaces and delete them. In CQL, there is no query to list all keyspaces. How can I drop all Keyspaces from Cassandra, without knowing every single Keyspace

Re: How to clear all data using CQL?

2014-04-16 Thread Mark Reddy
To get a list of all keyspaces via CQL you can run: *describe keyspaces *or *select keyspace_name from system.schema_keyspaces;* On Wed, Apr 16, 2014 at 9:23 AM, Sebastian Schmidt isib...@gmail.comwrote: Hey I want to do unit tests for software that uses Cassandra as storage backend. Using

Re: How to clear all data using CQL?

2014-04-16 Thread Sebastian Schmidt
Thank you that worked! Am 16.04.2014 10:46, schrieb Mark Reddy: /select keyspace_name from system.schema_keyspaces;/

Re: How to clear all data using CQL?

2014-04-16 Thread James Horey
If you’re running unit tests and repeatadly clearing the Cassandra keyspaces, you may want to check out Ferry (ferry.opencore.io). It lets you standup/destroy multiple Cassandra stacks locally on your machine and is useful for the use case you described. I’m the author of Ferry, and would be