Table Options with MariaDB Enterprise ColumnStore

Overview

MariaDB Enterprise ColumnStore's table options are used in CREATE TABLE and ALTER TABLE statements to define table characteristics.

Compatibility

  • MariaDB Enterprise ColumnStore 5

  • MariaDB Enterprise ColumnStore 6

Table Options with CREATE TABLE

To set table options for a new table with MariaDB Enterprise ColumnStore, set the table options in the CREATE TABLE statement:

CREATE TABLE hq_sales.invoices (
   invoice_id BIGINT UNSIGNED AUTO_INCREMENT NOT NULL,
   branch_id INT NOT NULL,
   customer_id INT,
   invoice_date DATETIME(6),
   invoice_total DECIMAL(13, 2),
   payment_method ENUM('NONE', 'CASH', 'WIRE_TRANSFER', 'CREDIT_CARD', 'GIFT_CARD'),
   PRIMARY KEY(invoice_id)
) ENGINE=ColumnStore DEFAULT CHARACTER SET = utf8;

Table Options with ALTER TABLE

To set table options for an existing table with MariaDB Enterprise ColumnStore, set the table options in the ALTER TABLE statement:

ALTER TABLE hq_sales.invoices
   COMMENT='Invoices entered at HQ';

Accepted Table Options

MariaDB Enterprise ColumnStore supports the following table options:

Table Option

Description

COMMENT

  • Specifies a user-readable comment for the table.

DEFAULT CHARACTER SET

  • Specifies the default character set for columns which do not have a different character set explicitly specified.

DEFAULT COLLATE

  • Specifies the default collation for columns which do not have a different collation explicitly specified.