Developers community number 1 connection string reference

Npgsql

This is a .NET Framework Class Library provided by Npgsql Development Team.
The class library is contained in the file Npgsql.dll.
Coding
Add a reference to the assembly Npgsql and include the Npgsql namespace. Instantiate a new NpgsqlConnection connection object. Set the connection string and open the connection.


   VB.NET code sample
Imports Npgsql
Dim myConnection As NpgsqlConnection = New NpgsqlConnection()
myConnection.ConnectionString = myConnectionString
myConnection.Open()
//execute queries, etc
myConnection.Close()


   C# code sample
using Npgsql;
NpgsqlConnection myConnection = new NpgsqlConnection();
myConnection.ConnectionString = myConnectionString;
myConnection.Open();
//execute queries, etc
myConnection.Close();


Description
Npgsql is a .Net Data Provider for Postgresql. It allows any program developed for .Net framework to access database server. It is implemented in 100% C# code. Works with Postgresql 7.x and above.
More info about this class library can be found at the Npgsql Development Team product page.
Connection Strings
The Npgsql class library can be used to connect to the following data sources.

To see the available connection options, navigate to the connection strings reference by clicking the data source link.
Additional info or comments on this class library? Want to submit content?

Send an e-mail to
Copyright © 2010 ConnectionStrings.com   |   All Rights Reserved   |   Powered by CSAS   |   Send feedback, articles, requests and more connection strings here.