aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastian <sebasjm@gmail.com>2024-01-09 18:38:59 -0300
committerSebastian <sebasjm@gmail.com>2024-01-09 18:38:59 -0300
commitd66b43e756f2b9f39e720b466fa34b25d0a7d522 (patch)
tree22188b09f11a4fe35f56b728fae14c70e7d9aad5
parent92d10fc076e807cfbbf40a7f846e0d3c1764c545 (diff)
downloadlibeufin-d66b43e756f2b9f39e720b466fa34b25d0a7d522.tar.gz
libeufin-d66b43e756f2b9f39e720b466fa34b25d0a7d522.tar.bz2
libeufin-d66b43e756f2b9f39e720b466fa34b25d0a7d522.zip
forget about pending cashout before running migration script
-rw-r--r--database-versioning/libeufin-bank-0002.sql5
1 files changed, 4 insertions, 1 deletions
diff --git a/database-versioning/libeufin-bank-0002.sql b/database-versioning/libeufin-bank-0002.sql
index 3c7f270c..8092f1e1 100644
--- a/database-versioning/libeufin-bank-0002.sql
+++ b/database-versioning/libeufin-bank-0002.sql
@@ -18,6 +18,9 @@ BEGIN;
SELECT _v.register_patch('libeufin-bank-0002', NULL, NULL);
SET search_path TO libeufin_bank;
+-- forget about all pending operations
+DELETE FROM cashout_operations WHERE local_transaction IS NULL;
+
-- TODO drop pending cashout operations
ALTER TABLE cashout_operations
DROP COLUMN challenge,
@@ -62,4 +65,4 @@ COMMENT ON COLUMN tan_challenges.retry_counter IS 'How many tries are left for t
COMMENT ON COLUMN tan_challenges.tan_channel IS 'TAN channel to use, if null use customer configured one';
COMMENT ON COLUMN tan_challenges.tan_info IS 'TAN info to use, if null use customer configured one';
-COMMIT; \ No newline at end of file
+COMMIT;