1

Use-case: I am trying to write data from a nodejs process running locally (on a docker container) to my locally running postgres server (no docker container). The nodejs process is able to connect to the server (setting the address to host.docker.internal solved that problem) however, when I attempt a simple "SELECT * FROM contact LIMIT 1" query, this error is returned:

{"type":"postgres error","request":"SELECT * FROM contact",
"error":{
"name":"error","length":106,
"severity":"ERROR",
"code":"42P01",
"position":"15",
"file":"parse_relation.c",
"line":"1376",
"routine":"parserOpenTable"}}

The relation error suggests the table is not found-- I created this table using a postgres client (postico) and have been able to successfully query the table's contents with other pg clients as well

I see multiple posts are suggesting running the sequelize db:migrate command, but would this be the right solution here?

I did not create a model nor a migration, and created the table directly in the table. Is there something else I may be overlooking that is producing this error?

2
  • What do you get if you run that in a SQL client? e.g. psql? Commented May 20, 2021 at 7:33
  • @horse_with_no_name I get back the expected result of the list of records Commented May 20, 2021 at 8:37

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.