Skip to content

Confirm before Apply Changes runs DROP COLUMN in the table designer #791

Closed

Description

@EVWorth

Severity: P1 (data safety)

What happens

  1. Open ?mock=connected. Expand shop > Tables, right-click orders and pick Design Table.
  2. Click the trash icon on the notes row.
  3. Click Apply Changes.

ALTER TABLE orders DROP COLUMN notes runs at once, on a DEV connection, with no preview and no confirmation. The only feedback is a green "Table saved successfully!". A single misclicked trash icon followed by Apply loses a column of data for good. DBeaver and DataGrip always show the ALTER script and ask before they persist it.

Cause

src/components/designer/TableDesigner.tsx:310-316: in alter mode handlePrimaryAction calls runSave() directly. Create mode opens SQLPreviewDialog. Only connections marked production get the store's own confirmation.

Fix

In alter mode, open SQLPreviewDialog before running, as create mode does. At minimum, require it whenever the diff contains DROP COLUMN, DROP INDEX, DROP FOREIGN KEY or a column type change.

Part of #783.

Activity

  1. added
    bug
    on Oct 21, 2026
  2. added a commit that references this issue on Oct 21, 2026
    39bc922
  3. added a commit that references this issue on Oct 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions