Skip to content

Commit 601551b

Browse files
committed
Set redeemer fee to null if it is not null
Drastically speeds up the no ledger migration
1 parent 785d55b commit 601551b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cardano-db/src/Cardano/Db/Migration.hs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -396,7 +396,7 @@ readStageFromFilename fn =
396396
noLedgerMigrations :: SqlBackend -> Trace IO Text -> IO ()
397397
noLedgerMigrations backend trce = do
398398
void $ runDbIohkLogging backend trce $ do
399-
rawExecute "update redeemer set fee = null" []
399+
rawExecute "update redeemer set fee = null where fee is not null" []
400400
rawExecute "delete from reward" []
401401
rawExecute "delete from epoch_stake" []
402402
rawExecute "delete from ada_pots" []

0 commit comments

Comments
 (0)