0

In order to manage column updates more effectively cockroach db has a family feature: https://www.cockroachlabs.com/docs/stable/column-families.html

CREATE TABLE test (
    id INT PRIMARY KEY,
    last_accessed TIMESTAMP,
    data BYTES,
    FAMILY f1 (id, last_accessed),
    FAMILY f2 (data)
);

Is there any to describe liquibase script to create table with two or more families?

Something like

changes:
  - createTable:
      tableName: test
      columns:
        - column:
            constraints:
              primaryKey: true
              primaryKeyName: pk_id
            name: id
            type: INT
        - column:
            name: last_accessed 
            type: TIMESTAMP
        - column:
            name: data
            type: bytes
# not real liquibase yaml just question
      families:
        - family:
            name: f1
            columns:
            - id
            - last_accessed
        - family:
            name: f2
            columns:
            - data 

            
dmitryvim
  • 1,983
  • 4
  • 15
  • 27

1 Answers1

0

You can simply use SQL changeset or SQL change types.

Aditi
  • 357
  • 1
  • 7