Netsoft.Glaucus.MySQL 1.0.0

dotnet add package Netsoft.Glaucus.MySQL --version 1.0.0
NuGet\Install-Package Netsoft.Glaucus.MySQL -Version 1.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="Netsoft.Glaucus.MySQL" Version="1.0.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Netsoft.Glaucus.MySQL --version 1.0.0
#r "nuget: Netsoft.Glaucus.MySQL, 1.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.
// Install Netsoft.Glaucus.MySQL as a Cake Addin
#addin nuget:?package=Netsoft.Glaucus.MySQL&version=1.0.0

// Install Netsoft.Glaucus.MySQL as a Cake Tool
#tool nuget:?package=Netsoft.Glaucus.MySQL&version=1.0.0

Project Glaucus

Glaucus is an open source ASP.NET Core ORM, it allows programs written in C#, Visual Basic, F# to access several database servers, using their native Data Providers.

An ORM is an Object Relational Mapper, which is responsible for mapping between database and programming language.

Currently supports MSSQL, SQLite and MySQL official connectors and is very effective and powerful, yet simple to implement.

Database Engines

Glaucus currently supports the following databases (and more to come)

  • MS SQL,
  • SQLite,
  • MySQL

Installation

Glaucus is installed through NuGet: https://www.nuget.org/packages/Glaucus

PM> Install-Package Glaucus

Quick Start

  • More samples coming soon, please stay tune

The easiest way to start is using the vanilla queries and returning a DataTable
This sample will return a table with two fields:

var connectionString = ConfigurationManager.ConnectionStrings[0].ConnectionString;
var provider = new MSSqlProvider(connectionString);
using (var engine = new DbEngine(provider))
{
    var data = engine.Select("TableName", new[] { "field1", "fild2" });
    var datatable = data.ToDataTable();
}

Instead of using a DataTable (or DataSet) you may prefer to map your database to entity models, first create your model:

public class DummyItem
{
    string Field1 { get; set; }
    string Field2 { get; set; }
}
using (var engine = new DbEngine(provider))
{
    var data = engine.Select("TableName", new[] { "field1", "fild2" });
    var collection = data.ToList<DummyItem>();
}
  • More samples coming soon, please stay tune

Questions & Discussions

Please, do not hesitate to open an issue for any question you might have. I'm always more than happy to hear any feedback.

Contributions

I'm excited that you are interested in contributing to this ORM!
Anything from raising an issue, submitting an idea for a new feature, or making a pull request is welcome!

Please contribute using Github Flow. Create a branch, add commits, and open a pull request.

License

MIT. See full licence

Product Compatible and additional computed target framework versions.
.NET net5.0 was computed.  net5.0-windows was computed.  net6.0 was computed.  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 was computed.  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 was computed.  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. 
.NET Core netcoreapp2.1 is compatible.  netcoreapp2.2 was computed.  netcoreapp3.0 was computed.  netcoreapp3.1 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
1.0.0 577 11/26/2019