CREATE KEYSPACE

    The statement creates a keyspace that functions as a grouping mechanism for database objects (such as tables or ).

    create_keyspace

    keyspace_properties

    Grammar

    • keyspace_name and property_name are identifiers.
    • property_value is a literal of either , text, or datatype.
    • CQL keyspace properties are supported in the syntax but have no effect internally (where Yugabyte defaults are used instead).
    1. cqlsh> CREATE KEYSPACE example;
    1. example system_schema system_auth system
    1. CREATE KEYSPACE example WITH REPLICATION = {'class': 'SimpleStrategy', 'replication_factor': '3'} AND DURABLE_WRITES = true;
    1. ^^^^^^

    DROP KEYSPACEOther CQL Statements