-
Notifications
You must be signed in to change notification settings - Fork 34
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added migration to remove is_available_to_prime (zero-down migration)
- Loading branch information
1 parent
62a55fb
commit 650fce6
Showing
2 changed files
with
12 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
11 changes: 11 additions & 0 deletions
11
migrations/app/schema/20200602144311_remove_is_available_to_prime.up.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
-- Zero-down migrations (for a later PR/deployment) | ||
|
||
-- This is just meant to catch any older code that may have changed the old | ||
-- field during the previous deployment. | ||
UPDATE move_task_orders | ||
SET available_to_prime_at = updated_at | ||
WHERE is_available_to_prime = true | ||
AND available_to_prime_at IS NULL; | ||
|
||
ALTER TABLE move_task_orders | ||
DROP COLUMN is_available_to_prime; |