SwitchSoftware.Repositories.EntityFramework.MySql 9.0.0

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

SwitchSoftware.Repositories.EntityFramework.MySql

A MySQL-specific implementation of the SwitchSoftware.Repositories.EntityFramework repository pattern, built on top of Entity Framework Core.

Installation

Install-Package SwitchSoftware.Repositories.EntityFramework.MySql -Version 9.0.0

Or via the .NET CLI:

dotnet add package SwitchSoftware.Repositories.EntityFramework.MySql --version 9.0.0

Usage

Register your DbContext using Pomelo's UseMySql in your Program.cs or Startup.cs:

services.AddDbContext<YourDbContext>(options =>
    options.UseMySql(connectionString, ServerVersion.AutoDetect(connectionString)));

Then inject Repository<TEntity> or your derived repository classes as usual.

Version history and roadmap

Version EF Core MySQL Provider Status
9.0.0 9.x Pomelo.EntityFrameworkCore.MySql 9.0.0 ✅ Current recommended version
10.0.0 10.x MySql.EntityFrameworkCore (Oracle) ⚠️ Not recommended — see note below
10.0.1 10.x Pomelo.EntityFrameworkCore.MySql 10.x 🔜 Planned, pending Pomelo 10.0.0 release

⚠️ A note on version 10.0.0

Version 10.0.0 was published targeting EF Core 10 using Oracle's MySql.EntityFrameworkCore connector as a transitional measure. This version is not aligned with the project roadmap and should not be used. The intended MySQL provider for this package is always Pomelo, not Oracle's connector.

Roadmap

The project roadmap is to follow Pomelo's release cycle:

  • Once Pomelo.EntityFrameworkCore.MySql 10.0.0 is released (targeting EF Core 10), version 10.0.1 of this package will be published using that provider.
  • In the meantime, projects targeting net10.0 should use version 9.0.0 of this package. Pomelo officially supports running its 9.x releases on .NET 10 — the TargetFramework of your project and the version of EF Core/Pomelo are independent concerns. There is no functional or compatibility issue with using EF Core 9 + Pomelo 9 in a net10.0 project.

Dependencies

Product Compatible and additional computed target framework versions.
.NET net9.0 is compatible.  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 was computed.  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

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
10.0.0 174 6/17/2026 10.0.0 is deprecated.
9.0.0 1,483 6/23/2026
9.0.0-pre-release 132 1/27/2025
8.0.0 20,395 7/15/2024
7.0.3 539 5/21/2024
7.0.2 458 2/3/2023
6.0.13 5,472 2/2/2023
6.0.5 3,685 5/23/2022
6.0.4 600 5/23/2022
6.0.3 616 5/23/2022
6.0.2 587 5/23/2022
6.0.1 601 5/23/2022
6.0.0 626 5/23/2022
5.0.0 615 5/23/2022
3.1.25 661 5/23/2022
3.1.3 624 5/23/2022
3.1.2 600 5/23/2022
3.1.1 600 5/23/2022