SQL Syntax

CrateDB uses SQL to query documents.

This section of the documentation provides a full SQL syntax reference.

Note

If you’re just getting started with a particular part of CrateDB, we recommend you consult the appropriate top-level section of the documentation. The SQL syntax reference assumes a basic familiarity with the relevant parts of CrateDB.

  • General SQL
    • Constraints
    • Value Expressions
    • Lexical Structure
  • SQL Statements
    • ALTER CLUSTER
    • ALTER TABLE
    • ALTER USER
    • BEGIN
    • COMMIT
    • COPY FROM
    • COPY TO
    • CREATE ANALYZER
    • CREATE BLOB TABLE
    • CREATE FUNCTION
    • CREATE INGEST RULE
    • CREATE REPOSITORY
    • CREATE SNAPSHOT
    • CREATE TABLE
    • CREATE USER
    • CREATE VIEW
    • DEALLOCATE
    • DELETE
    • DENY
    • DROP ANALYZER
    • DROP FUNCTION
    • DROP INGEST RULE
    • DROP REPOSITORY
    • DROP SNAPSHOT
    • DROP TABLE
    • DROP USER
    • DROP VIEW
    • EXPLAIN
    • GRANT
    • INSERT
    • KILL
    • OPTIMIZE
    • REFRESH
    • RESTORE SNAPSHOT
    • REVOKE
    • SELECT
    • SET and RESET
    • SET TRANSACTION
    • SET LICENSE
    • SHOW COLUMNS
    • SHOW CREATE TABLE
    • SHOW SCHEMAS
    • SHOW TABLES
    • SHOW (session settings)
    • UPDATE