RepoDb.PostgreSql 1.14.1

Prefix Reserved
There is a newer prerelease version of this package available.
See the version list below for details.
dotnet add package RepoDb.PostgreSql --version 1.14.1
                    
NuGet\Install-Package RepoDb.PostgreSql -Version 1.14.1
                    
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="RepoDb.PostgreSql" Version="1.14.1" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="RepoDb.PostgreSql" Version="1.14.1" />
                    
Directory.Packages.props
<PackageReference Include="RepoDb.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 RepoDb.PostgreSql --version 1.14.1
                    
#r "nuget: RepoDb.PostgreSql, 1.14.1"
                    
#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 RepoDb.PostgreSql@1.14.1
                    
#: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=RepoDb.PostgreSql&version=1.14.1
                    
Install as a Cake Addin
#tool nuget:?package=RepoDb.PostgreSql&version=1.14.1
                    
Install as a Cake Tool

PostgreSqlBuild PostgreSqlHome PostgreSqlVersion

RepoDb.PostgreSql — RepoDB for PostgreSQL

The PostgreSQL provider for RepoDB — a fast, lightweight .NET ORM that lets you use raw SQL and fluent operations side by side on the same connection.

Important Pages

  • GitHub Home — core library and source code.
  • Website — full documentation, API reference, and blog.

Community

Dependencies

  • Npgsql — PostgreSQL data provider.
  • RepoDb — the RepoDB core library.

License

Apache-2.0 — Copyright © 2019 Michael Camara Pendon


Installation

Install-Package RepoDb.PostgreSql

Or visit the installation page for more options.

Get Started

Initialize the bootstrapper once at application startup:

RepoDb.PostgreSqlBootstrap.Initialize();

Then use any RepoDB operation directly on your NpgsqlConnection:

Query

using (var connection = new NpgsqlConnection(ConnectionString))
{
	var customer = connection.Query<Customer>(c => c.Id == 10045);
}

Insert

var customer = new Customer
{
	FirstName = "John",
	LastName = "Doe",
	IsActive = true
};
using (var connection = new NpgsqlConnection(ConnectionString))
{
	var id = connection.Insert<Customer>(customer);
}

Update

using (var connection = new NpgsqlConnection(ConnectionString))
{
	var customer = connection.Query<Customer>(10045);
	customer.FirstName = "John";
	customer.LastUpdatedUtc = DateTime.UtcNow;
	var affectedRows = connection.Update<Customer>(customer);
}

Delete

using (var connection = new NpgsqlConnection(ConnectionString))
{
	var customer = connection.Query<Customer>(10045);
	var deletedCount = connection.Delete<Customer>(customer);
}

Visit the get-started page for the full PostgreSQL guide.

Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (3)

Showing the top 3 NuGet packages that depend on RepoDb.PostgreSql:

Package Downloads
RepoDb.PostgreSql.BulkOperations

An extension library that contains the official Bulk Operations of RepoDb for PostgreSQL.

NBomber.Sinks.Timescale

NBomber sink that writes metrics data to TimescaleDB

Fx.Data.SQL

Package Description

GitHub repositories (3)

Showing the top 3 popular GitHub repositories that depend on RepoDb.PostgreSql:

Repository Stars
mixcore/mix.core
🚀 A future-proof enterprise web CMS supporting both headless and decoupled approaches. Build any type of app with customizable APIs on ASP.NET Core/.NET Core. Completely open-source and designed for flexibility. Since 2018.
itlibrium/DDD-starter-dotnet
Sample implementation and comparison of various approaches to building DDD applications. Useful as a baseline to quickly start a DDD dot net project.
TwentyFourMinutes/Venflow
A brand new, fast and lightweight ORM, build for PostgreSQL.
Version Downloads Last Updated
1.14.2-beta1 0 7/2/2026
1.14.1 26 7/1/2026
1.14.0 285 6/28/2026
1.13.2-alpha1 2,680 2/26/2024
1.13.1 507,775 3/16/2023
1.13.0 26,287 11/2/2022
1.13.0-beta1 696 10/25/2022
1.13.0-alpha2 949 10/6/2022
1.13.0-alpha1 1,144 9/17/2022
1.3.2-alpha1 286 2/26/2024
1.1.5 177,835 2/18/2022
1.1.5-beta2 782 12/12/2021
1.1.5-beta1 1,544 10/22/2021
1.1.4 21,919 9/23/2021
1.1.4-beta2 451 9/17/2021
1.1.4-beta1 738 3/2/2021
1.1.3 76,317 2/6/2021
1.1.2 4,074 12/30/2020
1.1.1 11,497 10/3/2020
Loading failed