You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have this query which I can run manually in psql, but when trying to write it programatically with node-postgres i'm getting the error below.
How can I write this query against the DOCUMENT schema?
SELECT*FROM"DOCUMENT".document_metadata m
LEFT OUTER JOIN"DOCUMENT".document_attributes a
ONa.document_id=m.id
constquery=`SELECT * FROM "DOCUMENT".document_metadata m LEFT OUTER JOIN "DOCUMENT".document_attributes a ON a.document_id = m.id`constmetadata=awaitdb.query(query)
Error:
error: relation "DOCUMENT.document_metadata" does not exist
at Connection.parseE (/usr/src/app/node_modules/pg/lib/connection.js:602:11)
at Connection.parseMessage (/usr/src/app/node_modules/pg/lib/connection.js:399:19)
at Socket.<anonymous> (/usr/src/app/node_modules/pg/lib/connection.js:121:22)
at Socket.emit (events.js:189:13)
at addChunk (_stream_readable.js:284:12)
at readableAddChunk (_stream_readable.js:265:11)
at Socket.Readable.push (_stream_readable.js:220:10)
at TCP.onStreamRead [as onread] (internal/stream_base_commons.js:94:17)
The text was updated successfully, but these errors were encountered:
I have this query which I can run manually in psql, but when trying to write it programatically with node-postgres i'm getting the error below.
How can I write this query against the
DOCUMENT
schema?Error:
The text was updated successfully, but these errors were encountered: