CodeLogic.Data.PostgreSql 5.0.116-preview

This is a prerelease version of CodeLogic.Data.PostgreSql.
This package has a SemVer 2.0.0 package version: 5.0.116-preview+258072a.
dotnet add package CodeLogic.Data.PostgreSql --version 5.0.116-preview
                    
NuGet\Install-Package CodeLogic.Data.PostgreSql -Version 5.0.116-preview
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="CodeLogic.Data.PostgreSql" Version="5.0.116-preview" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="CodeLogic.Data.PostgreSql" Version="5.0.116-preview" />
                    
Directory.Packages.props
<PackageReference Include="CodeLogic.Data.PostgreSql" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add CodeLogic.Data.PostgreSql --version 5.0.116-preview
                    
#r "nuget: CodeLogic.Data.PostgreSql, 5.0.116-preview"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package CodeLogic.Data.PostgreSql@5.0.116-preview
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=CodeLogic.Data.PostgreSql&version=5.0.116-preview&prerelease
                    
Install as a Cake Addin
#tool nuget:?package=CodeLogic.Data.PostgreSql&version=5.0.116-preview&prerelease
                    
Install as a Cake Tool

CodeLogic.Data.PostgreSql

Status: 5.0 preview.

The PostgreSQL provider for CodeLogic.Data, built on Npgsql.

dotnet add package CodeLogic.Data.PostgreSql
  • With the CodeLogic runtime: load PostgreSqlDataLibrary next to DataLibrary, and set "provider": "postgresql" on a connection in config.data.json.
  • Without it: pass PostgreSqlDataProvider.Instance to Database.Create.

Bulk copy uses binary COPY with each column's real type; jsonb, uuid, timestamptz and bytea map natively; postgreSql.defaultSchema qualifies tables; replica lag comes from the replay LSN and timestamp; failoverHosts uses Npgsql multi-host. Extras: db.Postgres.ListenAsync, NotifyAsync, VacuumAnalyzeAsync<T>().

Documentation: Providers.

Product Compatible and additional computed target framework versions.
.NET net11.0 is compatible. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
5.0.116-preview 42 11/1/2026
5.0.115-preview 42 11/1/2026
5.0.114-preview 35 10/31/2026
5.0.113-preview 35 10/31/2026

# Changelog

## 5.0 (unreleased)

### Added

- New package: the PostgreSQL provider for CodeLogic.Data (CL.Data), built on Npgsql. Part of the CL.Data database
 framework that replaces CL.PostgreSQL in the CodeLogic 5 line. Targets .NET 11 and CodeLogic 5.
- Restores move identity sequences past the restored values (setval).

### Fixed

- `NotifyAsync` (`pg_notify`) and `VacuumAnalyzeAsync` run on the primary as a side effect (`SqlIntent.SideEffect`). Before, they went through the read path: a notification could be sent on a replica (where it fails) or sent twice after a transient error.
- The schema introspector always reads the primary.
- `[PostgresTable]` hints are applied when a table is created: `Unlogged` gives `CREATE UNLOGGED TABLE`, `FillFactor` gives `WITH (fillfactor = n)`, `Tablespace` gives `TABLESPACE`. Before, they were ignored.