Retour au classement

npgsql/efcore.pg

C#

Entity Framework Core provider for PostgreSQL

entity-frameworknpgsqlpostgrespostgresqlsqldatabaseentity-framework-coredotnet
Croissance des étoiles
Étoiles
1.8k
Forks
259
Croissance hebdomadaire
Issues
261
5001k1.5k
avr. 2016sept. 2019févr. 2023juil. 2026
README

Npgsql Entity Framework Core provider for PostgreSQL

stable next patch daily builds (vnext) build gitter

Npgsql.EntityFrameworkCore.PostgreSQL is the open source EF Core provider for PostgreSQL. It allows you to interact with PostgreSQL via the most widely-used .NET O/RM from Microsoft, and use familiar LINQ syntax to express queries. It's built on top of Npgsql.

The provider looks and feels just like any other Entity Framework Core provider. Here's a quick sample to get you started:

await using var ctx = new BlogContext();
await ctx.Database.EnsureDeletedAsync();
await ctx.Database.EnsureCreatedAsync();

// Insert a Blog
ctx.Blogs.Add(new() { Name = "FooBlog" });
await ctx.SaveChangesAsync();

// Query all blogs who's name starts with F
var fBlogs = await ctx.Blogs.Where(b => b.Name.StartsWith("F")).ToListAsync();

public class BlogContext : DbContext
{
    public DbSet<Blog> Blogs { get; set; }

    protected override void OnConfiguring(DbContextOptionsBuilder optionsBuilder)
        => optionsBuilder.UseNpgsql(@"Host=myserver;Username=mylogin;Password=mypass;Database=mydatabase");
}

public class Blog
{
    public int Id { get; set; }
    public string Name { get; set; }
}

Aside from providing general EF Core support for PostgreSQL, the provider also exposes some PostgreSQL-specific capabilities, allowing you to query JSON, array or range columns, as well as many other advanced features. For more information, see the the Npgsql site. For information about EF Core in general, see the EF Core website.

Dépôts similaires
jasontaylordev/CleanArchitecture

Clean Architecture Solution Template for ASP.NET Core

C#MIT Licenseclean-architecturetemplate
cleanarchitecture.jasontaylor.dev
20.3k4.2k
ent/ent

An entity framework for Go

GoGo ModulesApache License 2.0entorm
entgo.io
17.1k1k
dotnet/efcore

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

C#MIT Licenseentity-frameworkdatabase
learn.microsoft.com/ef/
14.8k3.4k
SanderMertens/flecs

A fast entity component system (ECS) for C & C++

COtherecsc99
flecs.dev
8.5k608
kgrzybek/sample-dotnet-core-cqrs-api

Sample .NET Core REST API CQRS implementation with raw SQL and DDD using Clean Architecture.

C#MIT Licensedddddd-example
kamilgrzybek.com/design/simple-cqrs-implementation-with-raw-sql-and-ddd/
3.1k676
PomeloFoundation/Pomelo.EntityFrameworkCore.MySql

Entity Framework Core provider for MySQL and MariaDB built on top of MySqlConnector

C#MIT Licenseentity-frameworkdotnet
3k415
xiaonanln/goworld

Scalable Distributed Game Server Engine with Hot Swapping in Golang

GoGo ModulesApache License 2.0golangrpc
2.7k476
thepirat000/Audit.NET

An extensible framework to audit executing operations in .NET

C#MIT Licenseaudit-logaudit
learnentityframeworkcore.com/extensions/audit-entityframework-core
2.6k328
ErikEJ/EFCorePowerTools

Entity Framework Core Power Tools - reverse engineering, migrations and model visualization in Visual Studio & CLI

C#MIT Licenseentity-framework-corevisual-studio
2.5k335
zzzprojects/EntityFramework-Plus

Entity Framework Plus extends your DbContext with must-haves features: Include Filter, Auditing, Caching, Query Future, Batch Delete, Batch Update, and more

C#MIT Licensecsharpdotnet
entityframework-plus.net
2.3k318
genaray/Arch

A high-performance C# based Archetype & Chunks Entity Component System (ECS) with optional multithreading.

C#Apache License 2.0csharpdotnet
arch-ecs.gitbook.io/arch
1.8k172
dotnet/EntityFramework.Docs

Documentation for Entity Framework Core and Entity Framework 6

MermaidCreative Commons Attribution 4.0 Internationaldocumentationorm
learn.microsoft.com/ef/
1.7k2k