Unwanted db.execute() behavior; trying to pass in an array instead of a record or its singular

When trying to pass an array (ex. number[], bigint[], string[]) that contains only one element into sql``​, it will be transformed into their non-list type (ex.
number
, bigint,
string
respectively).

When I put two elements in, it then turns into a Postgres record, which is not what I want. What I expect is that the array stays an array.

Was this page helpful?