I am getting this error message from prisma when I am running the GraphQL query.
Environment variable not found: DATABASE_URL.\n --> schema.prisma:6\n | \n 5 | provider = \"postgresql\"\n 6 | url = env(\"DATABASE_URL\")\n | \n\nValidation Error Count: 1",
At first, I didn't have the .env file in any of my project folders, then I added it with the link to the database url, still not working. Here is the folder structure:
This is what I have inside my .env
file looks like -
DATABASE_URL="postgres://postgres:[email protected]:5432/postgres"
DATABASE_URL="my value
and had forgotten the closing double-quote! So the value wasn't "there" becausedotenv
wasn't able to parse it correctly because of a mistake on my part. – Maffick