#Learning Next.js, Chapter 7: "Error: Failed to fetch revenue data."

4 messages · Page 1 of 1 (latest)

bitter garnet
#

Hey, I am currently going through the official learning course but got stuck on Chapter 7.

I keep getting the "Error: Failed to fetch revenue data." error. The message of the error itself is "Database Error: Error: Server error (HTTP status 404): Not Found".
I've attached the screenshots of the app/dashboard/page.tsx and app/lib/data.ts files as well as the error itself.

I'm certain that I have data in the database as I've checked it on supabase. Also, for test purposes, I've tried using db from "@vercel/postgres" and I managed to fetch the target data using db.

Would appreciate any ideas / suggestions on how I could make this work.

static pewterBOT
#

🔎 This post has been indexed in our web forum and will be seen by search engines so other users can find it outside Discord

🕵️ Your user profile is private by default and won't be visible to users outside Discord, if you want to be visible in the web forum you can add the "Public Profile" role in id:customize

✅ You can mark a message as the answer for your post with Right click -> Apps -> Mark Solution
(if you don't see the option, try refreshing Discord with Ctrl + R)

bitter garnet
#

Solved

I've changed the database provider on Vercel from Supabase to Neon and it has solved the issue and now I'm able to use sql from @vercel/postgres. Not sure why, but with Supabase I was not able to use it.

static pewterBOT