diff options
author | Christian Grothoff <christian@grothoff.org> | 2024-01-09 12:12:09 +0100 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2024-01-09 12:12:09 +0100 |
commit | 81400220f84892e869fb74a700d14fd4e26afb12 (patch) | |
tree | 86e78749dd176e137a57ae9a88f002c5b314d937 /src | |
parent | be6a38906f42b44032616e77c59191eda3eb68cd (diff) |
fix SQL
Diffstat (limited to 'src')
-rw-r--r-- | src/auditordb/0002-auditor-triggers.sql | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/src/auditordb/0002-auditor-triggers.sql b/src/auditordb/0002-auditor-triggers.sql index 43d8eb8f6..ce4b66b7b 100644 --- a/src/auditordb/0002-auditor-triggers.sql +++ b/src/auditordb/0002-auditor-triggers.sql @@ -1,19 +1,20 @@ SET search_path TO auditor; -CREATE TRIGGER auditor_notify_helper_deposits - AFTER INSERT - ON auditor.deposit_confirmations -EXECUTE PROCEDURE auditor_new_transactions_trigger(); - CREATE OR REPLACE FUNCTION auditor_new_transactions_trigger() RETURNS trigger LANGUAGE plpgsql AS $$ BEGIN -- TODO Add correct notify string - PERFORM('NOTIFY XRE2709K6TYDBVARD9Y5SCZY7VHE4D5DKF0R8DHQ4X5T13E8X2X60'); + NOTIFY XRE2709K6TYDBVARD9Y5SCZY7VHE4D5DKF0R8DHQ4X5T13E8X2X60; RETURN NEW; END $$; COMMENT ON FUNCTION auditor_new_transactions_trigger() IS 'Call auditor_call_db_notify on new entry'; + +CREATE TRIGGER auditor_notify_helper_deposits + AFTER INSERT + ON auditor.deposit_confirmations +EXECUTE PROCEDURE auditor_new_transactions_trigger(); + |