CHECK and FOREIGN KEY constraint names to be unique across the whole schema. Because an online schema change builds a copy of the table alongside the original, PlanetScale gives every constraint on the copy a new name: the original name plus a generated suffix such as orders_amount_chk_5vtaqz7kepok6wa91vryrkrje. The suffix changes every time the table goes through a deploy. See Foreign key constraint names change on every deployment.
When the deploy runs, the DROP must name the constraint exactly as it exists on the production table at that moment. If the table was deployed again after this deploy request’s changes were computed, or the name recorded for the production branch is out of date, the names no longer match and the deploy stops.
How to fix it
Check the current name on the production branch:1
Close or cancel the failed deploy request.
2
Create a fresh branch from the production branch so it picks up the current constraint names.
3
Apply your schema change on the new branch and open a new deploy request.

