NeonN
Neon2y ago
5 replies
worthy-azure

Connection string in .NET

Hey! Trying to connect to neon from a .NET application. I figured using Npgsql would be the happy path since it is a PostgreSQL database, but I can't quite figure out how I should form my connection string. Seems like there aren't a lot of .NET people using Neon yet, so no guide up on the website, but I wouldn't mind writing up a first draft for a language guide on .NET.

Right now I'm just passing what I was provided in the "connection string" field but I'm getting an error from Npgsql, Format of the initialization string does not conform to specification starting at index 0.

This is what I am passing:
postgresql://********:************@************************.eu-central-1.aws.neon.tech/neondb?sslmode=require
Was this page helpful?