Neon Releases Security & compliance Stability

Destructive migration drops table with no rollback path

Part of the Branching & migrations check · fix arrives as a draft

What it is

A migration drops a table with no rollback path and no archival of the data first.

Why it matters

The data is gone when it runs. Recovery means a PITR restore, which brings back everything else to that moment too — so the fix for one bad migration is losing every write since.

How to fix it

Copy the data to a backup table before dropping, and write the down-migration. Better, stop writing to the table in one release and drop it in a later one once you are confident nothing reads it.

Run them all on your app

Connect your repo and your live services with read-only scopes. The first scan is free, and nothing changes without your approval.