PrismaP
Prisma8mo ago
15 replies
piscopancer

`DATABASE_URL` invalid while `npx prisma migrate ...`??

Environment variables loaded from .env
Prisma schema loaded from schema.prisma
Datasource "db": PostgreSQL database

Error: P1013: The provided database string is invalid. The scheme is not recognized in database URL. Please refer to the documentation in https://www.prisma.io/docs/reference/database-reference/connection-urls for constructing a correct connection string. 
In some cases, certain characters must be escaped. Please check 
the string for any illegal characters.
Solution
@piscopancer
url = env("DATABASE_URL")
(without quotes)
Was this page helpful?