aboutsummaryrefslogtreecommitdiffstats
path: root/sql/dawn.sql
diff options
context:
space:
mode:
Diffstat (limited to 'sql/dawn.sql')
-rw-r--r--sql/dawn.sql12
1 files changed, 7 insertions, 5 deletions
diff --git a/sql/dawn.sql b/sql/dawn.sql
index f66ddbdc..f32a3a23 100644
--- a/sql/dawn.sql
+++ b/sql/dawn.sql
@@ -607,10 +607,15 @@ CREATE TRIGGER fx_portf BEFORE
INSERT OR UPDATE OF
folder
ON
- wires
+ spots
FOR EACH ROW
EXECUTE PROCEDURE update_portf2();
+CREATE TRIGGER dealid BEFORE
+INSERT ON
+spots
+FOR EACH ROW
+EXECUTE PROCEDURE auto_dealid();
CREATE TABLE fx_swaps (
id int4 NOT NULL GENERATED BY DEFAULT AS IDENTITY PRIMARY KEY,
@@ -667,10 +672,7 @@ CREATE TABLE terminations (
fee_payment_date date NOT NULL,
);
-create
- trigger dealid after insert
- on
- spots for each row execute procedure auto_dealid();;
+
CREATE OR REPLACE FUNCTION auto_dealid()
RETURNS TRIGGER AS $$