Browse Source

fix: DATEADD - cast arg value to date

pull/7268/head
Pranav C 11 months ago
parent
commit
c9e64ed146
  1. 2
      packages/nocodb/src/db/functionMappings/pg.ts

2
packages/nocodb/src/db/functionMappings/pg.ts

@ -57,7 +57,7 @@ const pg = {
DATEADD: async ({ fn, knex, pt, colAlias }: MapFnArgs) => {
return {
builder: knex.raw(
`${(await fn(pt.arguments[0])).builder} + (${
`(${(await fn(pt.arguments[0])).builder})::DATE + (${
(await fn(pt.arguments[1])).builder
} ||
'${String((await fn(pt.arguments[2])).builder).replace(

Loading…
Cancel
Save