Open-Awesome
CategoriesAlternativesStacksSelf-HostedExplore
Open-Awesome

© 2026 Open-Awesome. Curated for the developer elite.

TermsPrivacyAboutGitHubRSS
  1. Home
  2. .NET
  3. LINQ to DB

LINQ to DB

MITC#v6.3.0

A fast, type-safe LINQ database access library that sits between micro-ORMs and full ORMs, offering SQL-like control with LINQ expressions.

GitHubGitHub
3.3k stars478 forks0 contributors

What is LINQ to DB?

LINQ to DB is a .NET library that provides fast, type-safe database access using LINQ queries. It translates LINQ expressions into SQL, offering a lightweight layer between your code and the database. It solves the problem of writing raw SQL with string concatenation while avoiding the overhead and complexity of full-fledged ORMs.

Target Audience

.NET developers who need high-performance database access with LINQ, especially those transitioning from micro-ORMs like Dapper or seeking an alternative to Entity Framework. It's also suitable for F# developers looking for type-safe database querying.

Value Proposition

Developers choose LINQ to DB for its balance of speed, control, and type safety. It provides more abstraction than micro-ORMs without the bloat of full ORMs, and its queries are compiler-checked, reducing runtime errors. The library is optimized for performance and supports advanced SQL features like bulk operations and window functions.

Overview

Linq to database provider.

Use Cases

Best For

  • High-performance data access in .NET applications
  • Replacing raw SQL strings with type-safe LINQ queries
  • Applications needing bulk insert/copy operations
  • Projects requiring fine-grained control over SQL generation
  • F# development with database interactions
  • Scenarios where Entity Framework is too heavy or slow

Not Ideal For

  • Teams that rely on automatic change tracking and built-in migration tools, such as those using Entity Framework Core's code-first workflows.
  • Projects requiring rapid prototyping with zero-configuration ORM setups where convention-based mapping is sufficient.
  • Environments where developers prefer the simplicity of raw SQL with micro-ORMs like Dapper and see LINQ abstraction as unnecessary overhead.

Pros & Cons

Pros

Compiler-Checked Queries

Uses LINQ expressions instead of magic strings, enabling C# compiler validation and easy refactoring, as highlighted in the architecture description.

High-Performance Operations

Marketed as the fastest LINQ database access library, with features like bulk copy/insert for efficient large data transfers, emphasizing speed over full ORM bloat.

Advanced SQL Support

Supports complex SQL scenarios such as CTEs, window functions, and a Merge API, providing fine-grained control without sacrificing LINQ convenience.

Flexible Mapping Options

Allows attribute-based, fluent, or inferred mapping of POCOs, catering to different project needs without forcing a single approach, as detailed in the configuration sections.

Cons

No Built-In Change Tracking

Requires manual management of entity states for updates, increasing boilerplate code compared to ORMs like Entity Framework that handle this automatically.

Verbose Configuration

Mapping POCOs to database tables demands explicit setup through attributes or fluent configuration, which can be time-consuming for large domain models.

Learning Curve for Optimization

Developers must understand how LINQ queries translate to SQL to avoid performance pitfalls, which might be challenging for teams unfamiliar with database internals.

Open Source Alternative To

LINQ to DB is an open-source alternative to the following products:

E
Entity Framework

Entity Framework is an object-relational mapper (ORM) for .NET that enables developers to work with databases using .NET objects.

L
LINQ to SQL

Frequently Asked Questions

Quick Stats

Stars3,303
Forks478
Contributors0
Open Issues316
Last commit21 hours ago
CreatedSince 2011

Tags

#orm#database#access#linq#micro-orm#data-access#entity-framework-alternative#dotnet#postgresql#bulk-operations#type-safe#mysql#db2#firebird#sql

Built With

F
F#
.
.NET
C
C++

Included in

.NET21.2k
Auto-fetched 7 hours ago

Related Projects

DapperDapper

Dapper - a simple object mapper for .Net

Stars18,357
Forks3,669
Last commit2 months ago
Entity Framework CoreEntity Framework Core

EF Core is a modern object-database mapper for .NET. It supports LINQ queries, change tracking, updates, and schema migrations.

Stars14,751
Forks3,402
Last commit17 hours ago
SqlSugarSqlSugar

.Net aot ORM SqlServer ORM Mongodb ORM MySql 瀚高 Postgresql ORM DB2 Hana 高斯 Duckdb C# VB.NET Sqlite ORM Oracle ORM Mysql Orm 虚谷数据库 达梦 ORM 人大金仓 ORM 神通ORM C# ORM , C# ORM .NET ORM NET9 ORM .NET8 ORM ClickHouse ORM QuestDb ,TDengine ORM,OceanBase ORM,GaussDB ORM,Tidb ORM Object/Relational Mapping

Stars5,827
Forks1,390
Last commit2 days ago
ServiceStack.OrmLiteServiceStack.OrmLite

Thoughtfully architected, obscenely fast, thoroughly enjoyable web services for all

Stars5,498
Forks1,609
Last commit2 days ago
Community-curated · Updated weekly · 100% open source

Found a gem we're missing?

Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.

Submit a projectStar on GitHub