fix interval in sql template
This commit is contained in:
parent
153f47de7d
commit
bcd8adae45
@ -482,7 +482,7 @@ const resolvers = {
|
|||||||
FROM "Withdrawl"
|
FROM "Withdrawl"
|
||||||
WHERE "userId" = ${me.id}
|
WHERE "userId" = ${me.id}
|
||||||
AND id = ${Number(id)}
|
AND id = ${Number(id)}
|
||||||
AND now() > created_at + interval '${retention}'
|
AND now() > created_at + ${retention}::INTERVAL
|
||||||
AND hash IS NOT NULL
|
AND hash IS NOT NULL
|
||||||
AND status IS NOT NULL
|
AND status IS NOT NULL
|
||||||
), updated_rows AS (
|
), updated_rows AS (
|
||||||
|
@ -346,7 +346,7 @@ export async function autoDropBolt11s ({ models, lnd }) {
|
|||||||
SELECT id, hash, bolt11
|
SELECT id, hash, bolt11
|
||||||
FROM "Withdrawl"
|
FROM "Withdrawl"
|
||||||
WHERE "userId" IN (SELECT id FROM users WHERE "autoDropBolt11s")
|
WHERE "userId" IN (SELECT id FROM users WHERE "autoDropBolt11s")
|
||||||
AND now() > created_at + interval '${retention}'
|
AND now() > created_at + ${retention}::INTERVAL
|
||||||
AND hash IS NOT NULL
|
AND hash IS NOT NULL
|
||||||
AND status IS NOT NULL
|
AND status IS NOT NULL
|
||||||
), updated_rows AS (
|
), updated_rows AS (
|
||||||
|
Loading…
x
Reference in New Issue
Block a user