R
Railwayβ€’11mo ago
VINCENT

Error: P1001: Can't reach database server

anybody any help ?
25 Replies
Percy
Percyβ€’11mo ago
Project ID: N/A
Brody
Brodyβ€’11mo ago
going to need much more information than this
VINCENT
VINCENTOPβ€’11mo ago
thank you , what do you need me to do ?
Brody
Brodyβ€’11mo ago
where do you get this error tell me more information, any information
VINCENT
VINCENTOPβ€’11mo ago
in my vs code via termianl using command "npx prisma migrate dev" "dependencies": { "@prisma/client": "^5.7.1", "@types/node": "20.10.6", "@types/react": "18.2.46", "@types/react-dom": "18.2.18", "next": "14.0.4", "prisma": "^5.7.1", "react": "18.2.0", "react-dom": "18.2.0", "ts-node": "^10.9.2", "typescript": "5.3.3" },
Brody
Brodyβ€’11mo ago
where have you set the database credentials for local use?
VINCENT
VINCENTOPβ€’11mo ago
Postgres if i understood your question correctly
Brody
Brodyβ€’11mo ago
where have you set the database url variable so that you can use it locally
VINCENT
VINCENTOPβ€’11mo ago
in .env file DATABASE_URL = "the url"
Brody
Brodyβ€’11mo ago
is prisma setup to load the variables from that .env file?
VINCENT
VINCENTOPβ€’11mo ago
datasource db { provider = "postgresql" url = env("DATABASE_URL") } in the file schema.prisma seems counfusing dosen`t it ?
Brody
Brodyβ€’11mo ago
but are the variables in your .env file being loaded before running the migrations
VINCENT
VINCENTOPβ€’11mo ago
idk how can ensure that?
Brody
Brodyβ€’11mo ago
that would be a question for prisma's documentation and side question, can you connect to the database on railway with something like dbgate?
VINCENT
VINCENTOPβ€’11mo ago
you think the problem lies in prisma configuration ? and what is even that
Brody
Brodyβ€’11mo ago
a database client
VINCENT
VINCENTOPβ€’11mo ago
damn i`m too noob
Brody
Brodyβ€’11mo ago
no worries we all start somewhere
VINCENT
VINCENTOPβ€’11mo ago
you got me emmotinal bro for that i got no answer becuz everbody working with prisma so ii just follow it
Brody
Brodyβ€’11mo ago
have you tried connecting to the database with dbgate yet?
VINCENT
VINCENTOPβ€’11mo ago
no where can ii learn that i have no experince in back-end what so ever
Brody
Brodyβ€’11mo ago
we all start somewhere but you can start by googling for dbgate πŸ˜‰ don't overthink this
VINCENT
VINCENTOPβ€’11mo ago
ok if you would give me easy tools to get me up and running with next js what would that be ?
Brody
Brodyβ€’11mo ago
please try connecting to your railway database with dbgate
VINCENT
VINCENTOPβ€’11mo ago
thanks i`ll see to plus2salute
Want results from more Discord servers?
Add your server