Direct Postgres connection to Supabase from Vercel Edge in Next.js

This page summarizes the projects mentioned and recommended in the original post on /r/nextjs

Our great sponsors
  • SurveyJS - Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App
  • WorkOS - The modern identity platform for B2B SaaS
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • storage

    Vercel Postgres, KV, Blob, and Edge Config (by vercel)

  • Is anyone aware of a way to make a direct connection to Postgres with transaction support on Vercel Edge functions? The 'pg' package doesn't work on edge for me. The obvious answer would be @vercel/postgres but I find their lack of documentation rough and for whatever reason I can't get it to connect on my local computer using the Supabase-provided local database connection string. This is apparently a known issue (https://github.com/vercel/storage/issues/123, https://github.com/vercel/examples/issues/701) where in order to make this (or neon's package) work you need a WebSocket proxy? Is a direct Postgres connection from edge just impossible right now? Or do others have it working somehow?

  • examples

    Enjoy our curated collection of examples and solutions. Use these patterns to build your own robust and scalable applications. (by vercel)

  • Is anyone aware of a way to make a direct connection to Postgres with transaction support on Vercel Edge functions? The 'pg' package doesn't work on edge for me. The obvious answer would be @vercel/postgres but I find their lack of documentation rough and for whatever reason I can't get it to connect on my local computer using the Supabase-provided local database connection string. This is apparently a known issue (https://github.com/vercel/storage/issues/123, https://github.com/vercel/examples/issues/701) where in order to make this (or neon's package) work you need a WebSocket proxy? Is a direct Postgres connection from edge just impossible right now? Or do others have it working somehow?

  • SurveyJS

    Open-Source JSON Form Builder to Create Dynamic Forms Right in Your App. With SurveyJS form UI libraries, you can build and style forms in a fully-integrated drag & drop form builder, render them in your JS app, and store form submission data in any backend, inc. PHP, ASP.NET Core, and Node.js.

    SurveyJS logo
NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts