OrmLite Installation

OrmLite packages are available on NuGet and can be installed using your IDE or by adding a PackageReference in your .csproj

PostgreSQL

Supports .NET 6+, .NET Framework v4.7.2+ and .NET Standard 2.0 (.NET 5 and lower)

<PackageReference Include="ServiceStack.OrmLite.PostgreSQL" Version="6.*" />

SQL Server

Uses Microsoft.Data.SqlClient ADO .NET provider. Supports .NET 6+ and .NET Standard 2.0 (.NET 5 and lower)

<PackageReference Include="ServiceStack.OrmLite.SqlServer.Data" Version="6.*" />

Uses System.Data.SqlClient. Supports .NET 6+, .NET Framework v4.7.2+ and .NET Standard 2.0 (.NET 5 and lower)

<PackageReference Include="ServiceStack.OrmLite.SqlServer" Version="6.*" />

MySql

Uses Mysql.Data. Supports .NET 6+, .NET Framework v4.7.2+ and .NET Standard 2.0 (.NET 5 and lower)

<PackageReference Include="ServiceStack.OrmLite.MySql" Version="6.*" />

Uses MySqlConnector. Supports .NET 6+, .NET Framework v4.7.2+ and .NET Standard 2.0 (.NET 5 and lower)

<PackageReference Include="ServiceStack.OrmLite.MySqlConnector" Version="6.*" />

SQLite

Uses System.Data.SQLite. Supports .NET 6+, .NET Framework v4.7.2+ and .NET Standard 2.0 (.NET 5 and lower)

<PackageReference Include="ServiceStack.OrmLite.Sqlite" Version="6.*" />

Uses Microsoft.Data.Sqlite. Supports .NET 6+ and .NET Standard 2.0 (.NET 5 and lower)

<PackageReference Include="ServiceStack.OrmLite.Sqlite.Data" Version="6.*" />

Uses SQLitePCLRaw.bundle_cil for a managed implementation free of native binaries. Still in Preview but passes 100% test suite.

<PackageReference Include="ServiceStack.OrmLite.Sqlite.Cil" Version="6.*" />

.NET 6 & .NET Standard 2.0 only packages

The .Core packages contains only .NET 6 and .NET Standard 2.0 versions which can be used in ASP.NET Core Apps on .NET Framework:

<PackageReference Include="ServiceStack.OrmLite.SqlServer.Core" Version="6.*" />

<PackageReference Include="ServiceStack.OrmLite.PostgreSQL.Core" Version="6.*" />

<PackageReference Include="ServiceStack.OrmLite.MySql.Core" Version="6.*" />

<PackageReference Include="ServiceStack.OrmLite.Sqlite.Core" Version="6.*" />

Community Providers

Unofficial providers contributed and supported by ServiceStack Community users:

<PackageReference Include="ServiceStack.OrmLite.Oracle" Version="6.*" />

<PackageReference Include="ServiceStack.OrmLite.Firebird" Version="6.*" />

Please raise support questions on StackOverflow or ServiceStack/Discuss for best chance to reach community users.

Quick install in ASP .NET Core with mix

The quickest way to install OrmLite in existing ASP .NET Core projects is to mix in the desired RDBMS provider which both installs the required NuGet package and creates a Modular Startup configuration all setup to read your App's configured RDBMS connection string for instant utility:

x mix postgres

x mix sqlserver

x mix mysql

x mix sqlite

x mix oracle

x mix firebird

If you don't have the dotnet x tool installed, it can be installed with:

dotnet tool install -g x