You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
CREATETRIGGERset_logical_uniqueness_on_users BEFORE UPDATEON users FOR EACH ROW
SETNEW.logical_uniqueness= CASE
WHEN NEW.deleted_at IS NULL THEN 1
WHEN NEW.deleted_atIS NOT NULL THEN NULL
END;
Current output
found syntax error when parsing DDL "CREATE TRIGGER set_logical_uniqueness_on_users BEFORE UPDATE ON users FOR EACH ROW
SET NEW.logical_uniqueness = CASE
WHEN NEW.deleted_at is null then 1
WHEN NEW.deleted_at is not null then null
END": syntax error at position 128 near 'new'
Expected output
-- Apply --
CREATE TRIGGER set_logical_uniqueness_on_users BEFORE UPDATE ON users FOR EACH ROW SET NEW.logical_uniqueness = CASE WHEN NEW.deleted_at IS NULL THEN 1 WHEN NEW.deleted_at IS NOT NULL THEN NULL END;
The text was updated successfully, but these errors were encountered:
--export output
Input SQL
Current output
Expected output
The text was updated successfully, but these errors were encountered: