FreeSql is an object-relational mapper for .NET applications. It provides APIs for querying and modifying relational databases while mapping database records to C# objects.
The ORM supports .NET Core, .NET Framework, Xamarin, and ahead-of-time compilation scenarios. It offers several development models, including direct FreeSql access, DbContext with repositories and units of work, and a simplified BaseEntity approach.
This is free and open source software.
Key Features
- Supports Code First schema creation and database migrations.
- Generates entity classes from existing databases using DbFirst tools.
- Provides strongly typed queries using LINQ expression trees.
- Handles one-to-one, one-to-many, and many-to-many relationships.
- Offers eager loading, cascading operations, and lazy loading.
- Supports repositories, units of work, transactions, and dependency injection.
- Provides read/write separation, table partitioning, database sharding, and global filters.
- Supports optimistic and pessimistic locking.
- Works with MySQL, MariaDB, PostgreSQL, SQL Server, Oracle, SQLite, Firebird, ClickHouse, DuckDB, TDengine, QuestDB, Microsoft Access, and other databases.
- Allows custom data-type mappings and expression-function translation.
Website: github.com/dotnetcore/FreeSql
Support:
Developer: YeXiangQin
License: MIT License
FreeSql is written in C#. Learn C# with our recommended free books and free tutorials.
Related Software
| C# Object-Relational Mapping Software | |
|---|---|
| Entity Framework Core | Modern object-database mapper for .NET. |
| Dapper | Simple object mapper for .NET |
| NHibernate | Mature, open source object-relational mapper for .NET |
| LINQ to DB | LINQ database access library |
| RepoDB | Hybrid ORM library for .NET |
| Venflow | Fast and lightweight ORM for PostgreSQL |
Read our verdict in the software roundup.
Explore our comprehensive directory of recommended free and open source software. Our carefully curated collection spans every major software category.This directory is part of our ongoing series of informative articles for Linux enthusiasts. It features hundreds of detailed reviews, along with open source alternatives to proprietary solutions from major corporations such as Google, Microsoft, Apple, Adobe, IBM, Cisco, Oracle, and Autodesk. You’ll also find interesting projects to try, hardware coverage, free programming books and tutorials, and much more. Discovered a useful open source Linux program that we haven’t covered yet? Let us know by completing this form. |


Please read our Comment Policy before commenting.