akdom akdom - 5 months ago 55
C# Question

C# .NET + PostgreSQL

I'm looking at working on a project which uses C#.NET (sitting on a windows box) as the primary language and PostgreSQL as the backend database (backend is sitting on a linux box). I've heard that ODBC.NET allows for easy integration of these two components.

Has anyone had experience actually setting C# and PostgreSQL up to work together? If so, do you have any suggestions about how to go about it, issues you've found, etc.?


I'm working with C# and Postgres using Npgsql2 component, and they work fast, I recommend you.

You can download from https://github.com/npgsql/Npgsql/releases

Note: If you want an application that works with any database you can use the DbProviderFactory class and make your queries using IDbConnection, IDbCommand, IDataReader and/or IDbTransaction interfaces.