Represents a connection to a database, implementing the
IDatabase
interface.
- Namespace
- DbSyncKit
.PostgreSQL - Interfaces
- Base Types
-
- object
Syntax
public class Connection : IDatabase
Remarks
This class provides a generic representation of a database connection and includes methods
defined in the
IDatabase
interface for executing queries and managing transactions.
Constructors
Name | Summary |
---|---|
Connection |
Initializes a new instance of the Connection class with PostgreSQL server details. |
Properties
Name | Property Type | Summary |
---|---|---|
Provider | DatabaseProvider |
Gets the database provider type, which is PostgreSQL for this class.
|
Methods
Name | Return Value | Summary |
---|---|---|
ExecuteQuery |
DataSet |
Executes a query against the PostgreSQL database and returns the results as a DataSet.
|
GetConnectionString |
string |
Gets the connection string for the PostgreSQL database using provided server details.
|
TestConnection |
bool |
Tests the connection to the PostgreSQL database.
|