From b54b50d7a300917e177e3fafce975b72bf815c9f Mon Sep 17 00:00:00 2001
From: Jesse Luehrs <doy@tozt.net>
Date: Fri, 6 Sep 2019 03:57:46 -0400
Subject: fix syntax

---
 data/denorm.sql | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

(limited to 'data/denorm.sql')

diff --git a/data/denorm.sql b/data/denorm.sql
index 17c535a..915df09 100644
--- a/data/denorm.sql
+++ b/data/denorm.sql
@@ -56,7 +56,7 @@ CREATE VIEW denorm_transactions AS (
         ) LEFT JOIN accounts transfer_accounts ON (
             transactions_with_subtransactions.transfer_account_id = transfer_accounts.id
         ) LEFT JOIN tins ON (
-            tins.tin = regexp_match(memo, '\mtin:([^ ]+)')[1]
+            tins.tin = (regexp_match(memo, '\mtin:([^ ]+)'))[1]
         )
 );
 
@@ -112,7 +112,7 @@ CREATE VIEW denorm_scheduled_transactions AS (
         ) LEFT JOIN accounts transfer_accounts ON (
             scheduled_transactions_with_subtransactions.transfer_account_id = transfer_accounts.id
         ) LEFT JOIN tins ON (
-            tins.tin = regexp_match(memo, '\mtin:([^ ]+)')[1]
+            tins.tin = (regexp_match(memo, '\mtin:([^ ]+)'))[1]
         )
 );
 
-- 
cgit v1.2.3-54-g00ecf

