-- Add migration script here
CREATE TABLE IF NOT EXISTS cqrs_ordering_product_customizations_query
(
    version           bigint CHECK (version >= 0) NOT NULL,

	name TEXT NOT NULL,
	customization_id UUID NOT NULL UNIQUE,
	product_id UUID NOT NULL,

	deleted BOOLEAN NOT NULL DEFAULT FALSE,
    UNIQUE(product_id, name),

    PRIMARY KEY (customization_id)
);
