Skip to content

Commit f86f6b5

Browse files
committed
Updated insertsteward, got it working.
1 parent 367cd21 commit f86f6b5

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

function/ts/insertsteward.sql

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,8 @@ AS $function$
1313
WITH newstew AS (
1414
SELECT stewardid,
1515
_databaseid AS dbid
16-
FROM ti.stewards AS stw WHERE (stw.contactid = _contactid)) AS stewardid
17-
WHERE NOT (stewardid =
18-
19-
20-
)
16+
FROM ti.stewards AS stw WHERE (stw.contactid = _contactid))
2117
insert into ti.stewarddatabases(stewardid, databaseid)
22-
values ((select stewardid from ti.stewards AS stw where (stw.contactid IN _contactid)), _databaseid)
18+
values ((select stewardid from ti.stewards AS stw where (stw.contactid = _contactid)), _databaseid)
2319
RETURNING stewardid
2420
$function$

0 commit comments

Comments
 (0)