How to list all cassandra tables

Niko Gamulin picture Niko Gamulin · Aug 1, 2016 · Viewed 67.3k times · Source

There are many tables in cassandra database, which contain column titled user_id. The values user_id are referred to user stored in table users. As some users are deleted, I would like to delete orphan records in all tables that contain column titled user_id.

Is there a way to list all tables using CassandraSQLContext or any other built-in method or custom procedure in order to avoid explicitly defining the list of tables?

Answer

Dan Borza picture Dan Borza · May 3, 2018

From cqlsh execute describe tables;