-
Notifications
You must be signed in to change notification settings - Fork 11
YDB DDL Examples
Anton Kovalenko edited this page Apr 24, 2024
·
4 revisions
CREATE TABLE `my_column_table` (
Key Uint64 not null,
Value String,
PRIMARY KEY (Key)
)
PARTITION BY HASH(Key)
WITH (
STORE = COLUMN,
AUTO_PARTITIONING_MIN_PARTITIONS_COUNT = 10
);
ALTER TABLE `my_table` ADD INDEX `name_index` GLOBAL ON (`name`);
ALTER TABLE `my-table` ADD CHANGEFEED `my_cdc` WITH (
FORMAT = 'JSON',
MODE = 'UPDATES'
);