Class PostgreSQLTools
- Namespace
- LinqToDB.DataProvider.PostgreSQL
- Assembly
- linq2db.dll
public static class PostgreSQLTools
- Inheritance
-
PostgreSQLTools
Properties
AutoDetectProvider
public static bool AutoDetectProvider { get; set; }
Property Value
DefaultBulkCopyType
[Obsolete("Use PostgreSQLOptions.Default.BulkCopyType instead.")]
public static BulkCopyType DefaultBulkCopyType { get; set; }
Property Value
NormalizeTimestampData
Enables normalization of DateTime and DateTimeOffset data, passed to query as parameter or passed to BulkCopy<T>(ITable<T>, IEnumerable<T>) APIs, to comform with Npgsql 6 requerements:
- convert DateTimeOffset value to UTC value with zero Offset
- Use Utc for DateTime timestamptz values
- Use Unspecified for DateTime timestamp values with Utc kind
true
.
[Obsolete("Use PostgreSQLOptions.Default.NormalizeTimestampData instead.")]
public static bool NormalizeTimestampData { get; set; }
Property Value
Methods
AsPostgreSQL<TSource>(IQueryable<TSource>)
[Sql.QueryExtension(null, Sql.QueryExtensionScope.None, typeof(NoneExtensionBuilder))]
public static IPostgreSQLSpecificQueryable<TSource> AsPostgreSQL<TSource>(this IQueryable<TSource> source) where TSource : notnull
Parameters
source
IQueryable<TSource>
Returns
- IPostgreSQLSpecificQueryable<TSource>
Type Parameters
TSource
CreateDataConnection(DbConnection, PostgreSQLVersion)
public static DataConnection CreateDataConnection(DbConnection connection, PostgreSQLVersion version = PostgreSQLVersion.AutoDetect)
Parameters
connection
DbConnectionversion
PostgreSQLVersion
Returns
CreateDataConnection(DbTransaction, PostgreSQLVersion)
public static DataConnection CreateDataConnection(DbTransaction transaction, PostgreSQLVersion version = PostgreSQLVersion.AutoDetect)
Parameters
transaction
DbTransactionversion
PostgreSQLVersion
Returns
CreateDataConnection(string, PostgreSQLVersion)
public static DataConnection CreateDataConnection(string connectionString, PostgreSQLVersion version = PostgreSQLVersion.AutoDetect)
Parameters
connectionString
stringversion
PostgreSQLVersion
Returns
GetDataProvider(PostgreSQLVersion, string?)
public static IDataProvider GetDataProvider(PostgreSQLVersion version = PostgreSQLVersion.AutoDetect, string? connectionString = null)
Parameters
version
PostgreSQLVersionconnectionString
string
Returns
ResolvePostgreSQL(Assembly)
public static void ResolvePostgreSQL(Assembly assembly)
Parameters
assembly
Assembly
ResolvePostgreSQL(string)
public static void ResolvePostgreSQL(string path)
Parameters
path
string