FS.Dapper
8.1.0
There is a newer version of this package available.
See the version list below for details.
See the version list below for details.
dotnet add package FS.Dapper --version 8.1.0
NuGet\Install-Package FS.Dapper -Version 8.1.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="FS.Dapper" Version="8.1.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add FS.Dapper --version 8.1.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: FS.Dapper, 8.1.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.
// Install FS.Dapper as a Cake Addin #addin nuget:?package=FS.Dapper&version=8.1.0 // Install FS.Dapper as a Cake Tool #tool nuget:?package=FS.Dapper&version=8.1.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
[8.1.0] - ChangeLog
- Added MySQL provider type: now is possibile choose from MySQL Data provider and MySQL Connector provider
[8.0.6] - ChangeLog
- Added readonly connection / connection string into constructor (optional, default value is null). If readonly connection or readonly connection string is null, primary connection will be used for SelectAsync and SingleAsync methods
- Minor fixes
[8.0.5] - ChangeLog
- MySQL Connector instead of MySQL Data;
- Added MS SQL Server support;
- Added PostgreSQL support.
Usage
First method (MSQL connection example):
This method use a reusable connection:
string cnString = "<yourConnectionString>";
IDBConnection dbCn = new MySqlConnection(cnString);
services.AddSingleton<IDapperService>(new DapperService(dbCn));
Second method (MS SQL Server connection string example)
DatabaseType accepted values:
- MySQL
- SQLServer
- PostgreSQL
this method create a new connection everytime:
services.AddScoped<IDapperService>(new DapperService(DatabaseType.SQLServer, "<yourConnectionString>"));
Support
If you like this package, please support author offering him a coffe
License
MIT License
Copyright (c) 2019 FRΛƝCƎƧCØ ƧØЯRƎƝTIƝØ
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net6.0 is compatible. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 is compatible. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
net6.0
- Dapper (>= 2.1.35)
- Microsoft.Data.SqlClient (>= 5.2.0)
- MySql.Data (>= 8.3.0)
- MySqlConnector (>= 2.3.6)
- Npgsql (>= 8.0.2)
-
net7.0
- Dapper (>= 2.1.35)
- Microsoft.Data.SqlClient (>= 5.2.0)
- MySql.Data (>= 8.3.0)
- MySqlConnector (>= 2.3.6)
- Npgsql (>= 8.0.2)
-
net8.0
- Dapper (>= 2.1.35)
- Microsoft.Data.SqlClient (>= 5.2.0)
- MySql.Data (>= 8.3.0)
- MySqlConnector (>= 2.3.6)
- Npgsql (>= 8.0.2)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on FS.Dapper:
Package | Downloads |
---|---|
FS.ClientCache
Client cache service for .NET Core |
GitHub repositories
This package is not used by any popular GitHub repositories.