Postgres issue
Posted by Ninja Space Content on Tuesday, May 18, 2021 Under: postgres
In : postgres
Tags: postgres psql issue psql: error: could not connect to server:
psql: error: could not connect to server: could not connect to server:
brew install postgres
To have launchd start postgresql now and restart at login:
brew services start postgresql
so, I copied and pasted brew services start postgresql
psql
in my terminal and it was giving me this error: psql: error: could not connect to server: FATAL: database "******injaspace" does not exist. createdb
in the terminal and it looks like my old databases were wipe out. So in order to get my existing database to work again like it did a couple of weeks ago, I had to create the database again so I entered:CREATE DATABASE roses;
because roses was what I called my database. So I went back to my project in Visual Studio Code, started the server and voila, the error went away. I seeded my data and it is back now. This took me a good 45 minutes to debug. Hope it'll help you.In : postgres
Ninja Space Content |
California |
![]() |