Baike.dev
All toolsOnline toolsAI codingTrendingOpen sourceNewsSubmit
Log in
< Back to tools
R

RepoDB

> 数据库
Open source

A hybrid ORM library for .NET.

1.9K stars0 likes4 views
WebsiteGitHub

About

A hybrid ORM library for .NET.


RepoDB is a high-performance data productivity platform for .NET developers. At its core is the popular hybrid-ORM library for .NET with clean and easy APIs.

It provides the flexibility to work the way you want — all through the IDbConnection interface. Write raw SQL when you need absolute control, or use the fluent APIs for more productivity, and switch seamlessly between both without sacrificing performance or maintainability.

Why RepoDB?

RepoDB solves a complex problem in the .NET data access space: making bulk operations simple. It is designed to efficiently move millions of records across different database providers. Imagine migrating massive datasets from legacy databases to modern, cloud-native platforms — efficiently, reliably, and with high performance.

As a Productivity Platform

It goes beyond the ORM with enterprise-grade capabilities for building, operating, and scaling with confidence:

  • ** Bulk Operations** — High-performance bulk inserts, updates, merges, and deletes built for demanding production workloads.
  • ** Data Replication** — Scalable data movement and synchronization across multiple database platforms.
  • ** Telemetry** — Immediate visibility into execution times, failures, and application behavior, with minimal configuration.

As a Hybrid-ORM

It stays close to the metal and remaining lightweight:

  • ** Easy to Use** — All operations are extension methods on IDbConnection. Open a connection and you're ready to go.
  • ** High Performance** — Compiled expressions are cached and reused. RepoDB understands your schema to generate the most efficient execution path ahead of time.
  • ** Memory Efficient** — Object properties, execution contexts, mappings, and SQL statements are extracted once and reused throughout the lifetime of your application.
  • ** Hybrid** — Use fluent methods for everyday CRUD, drop down to raw SQL for complex queries, or mix both — all within the same connection.
  • ** Battle-Tested** — Backed by thousands of unit and integration tests, and used in production systems worldwide.
  • ** Always Free** — Apache 2.0 licensed, forever open source.

As a Universal Connector

It bridges different database systems with a single, unified connectivity layer:

  • ** Universal Connectivity** — Works with any provider that implements IDbConnection, from SQL Server and PostgreSQL to ClickHouse, DB2, Oracle, and more.
  • ** Cross-Provider Data Movement** — Move data between different database engines without writing hand-rolled conversion logic.
  • ** Consistent API Surface** — The same fluent methods and conventions work identically regardless of the underlying provider.
  • ⚙️ Provider-Native Optimizations — Each connector is tuned to exploit the bulk and native capabilities of its target database.

Roadmap

RepoDB is evolving from an ORM into a broader data productivity platform, with Data Engineering capabilities — moving data between providers, on-premise or cloud-native — on the roadmap.

Read more about this through this article.

Get Started

Fluent operations (Query, Insert, Merge, Delete, Update, and more), batches and bulks are supported for DB providers mentioned below. Choose your database and follow the quick-start guide:

  • ClickHouse
  • DB2
  • EnterpriseDB
  • Firebird
  • MariaDB
  • MySQL
  • Oracle
  • PostgreSQL
  • SAP HANA
  • SQL Server
  • SQLite
  • Vertica

While raw SQL execution methods work with any ADO.NET-compatible provider:

  • ExecuteQuery
  • ExecuteNonQuery
  • ExecuteScalar
  • ExecuteReader
  • ExecuteQueryMultiple

Explore individual features in the documentation.

Databases on the Roadmap

We have envisioned the following databases to be supported to further grow the ecosystem.

  • AuroraDB
  • CockroachDB
  • DuckDB
  • KingbaseES
  • Redshift
  • Snowflake

Packages and Build Status

RepoDB ships as a core package plus provider-specific packages for each supported database, with optional bulk-operations add-ons.

See the full package list and build status.

Bulk Operations Support

Every supported database has a dedicated bulk-operations add-on (BulkInsert, BulkMerge, BulkUpdate, BulkDelete), each built on top of that provider's own fastest data-loading mechanism, with sync and async variants:

DB Provider Sync Async Class
ClickHouse ✅ ✅ ClickHouseBulkCopy / OPTIMIZE_ON_INSERT
DB2 ✅ ✅ DB2BulkCopy Native (Sync) / Db2BulkArrayBinder (Async Native)
EnterpriseDB ✅ ✅ EDBBulkCopy (via RepoDb.Connector.EnterpriseDb) via Npgsql Native
Firebird ✅ ✅ FirebirdCommandBatcher (via FbBatchCommand) Native
MariaDB ✅ ✅ MariaDbBulkCopy (via RepoDb.Connector.MariaDb) Native
MariaDB Connector ✅ ✅ MariaDbBulkCopy (via RepoDb.Connector.MariaDbConnector) Native
MySQL ✅ ✅ MySqlBulkCopy (via MySqlBulkLoader Native)
MySQL Connector ✅ ✅ MySqlConnectorBulkCopy Native
Oracle ✅ ✅ OracleBulkCopy Native / OracleBulkArrayBinder (Async Native)
PostgreSQL ✅ ✅ NpgsqlBinaryImporter Native
SAP HANA ✅ ⚠️ HanaBulkCopy Native (Sync) / AsyncOverAsync or SapHanaCommandBatcher
SQL Server ✅ ✅ SqlBulkCopy Native
Vertica ✅ ⚠️ VerticaBulkCopy (via VerticaCopyStream) / Async over Sync

Type Coercion

RepoDB uses ADO.NET's native coercion by default, keeping type mismatches visible and explicit. To enable automatic conversion:

csharp
GlobalConfiguration
    .Setup(new Options.GlobalConfigurationOptions()
    {
        ConversionType = ConversionType.Automatic
    })
    .UseSqlServer();

How RepoDB Compares

RepoDB sits between a micro-ORM and a full ORM. Each tool below makes different tradeoffs — pick the one that fits your project:

RepoDB Dapper Entity Framework
Abstraction level ✅ Hybrid — fluent CRUD + raw SQL ❌ Micro-ORM — raw SQL mapping ✅ Full ORM — LINQ, change tracking
Fluent CRUD API ✅ Yes (Insert, Query, Update, Delete, Merge, more) ❌ No — SQL per call ✅ Yes, via LINQ/DbSet
Raw SQL ✅ Yes, mixed freely with fluent calls ✅ Yes — its core model ✅ Yes, via FromSql
Change tracking ❌ None ❌ None ✅ Yes
Migrations ❌ None built-in ❌ None built-in ✅ Yes (EF Migrations)
Native Bulk ✅ Built-in, cross-provider ❌ Via extensions ❌ Via extensions/third-party
Insights / telemetry ✅ Built-in (RepoDb.Telemetry.Default) ❌ None built-in — manual or third-party (e.g. MiniProfiler) ✅ Built-in logging/interceptors; OTel via community packages
Performance ✅ Close to raw ADO.NET ✅ Close to raw ADO.NET ❌ Overhead from tracking/materialization
Best fit ✅ EF-like productivity without losing SQL control ✅ Thinnest possible SQL-to-object mapper ✅ Rich object graphs, LINQ, migrations

Dapper and Entity Framework are both excellent, mat

Issues· 0 open

View all issuesOpen on GitHub

No open issues yet, or sync has not completed.

> Tags

C#bulk-operationcsharpdotnetdotnet-core

No comments yet. Be the first to share.

> Details

PublishedAug 1, 2026
UpdatedSep 17, 2026
Category数据库
PricingOpen source

> Related tools

P
PostgreSQL
功能强大的开源关系型数据库
R
Redis
内存数据结构存储,常用作缓存与队列
M
MySQL
广泛使用的开源关系型数据库