I am trying to run the query:
let query =
`
DELETE FROM
${table_name}
WHERE
_id IN ($1::bigint[])
AND
account_id = $2
`
let fields =
[
_ids,
account_id,
]
but it's giving me the error:
operator does not exist: bigint = bigint[]
_ids
is an array.
NOTE
The error I was getting once implementing the answer was:
GraphQLError: Int cannot represent non-integer value: []
This was simply a GraphQL error, nothing to do with postgres.
GraphQLError: Int cannot represent non-integer value: []
and shouldn't it be bigint? Since the_id
isbigserial
– Worrisome