Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Non-GPL ADO.NET provider for MySQL?

Is there any NON-GPL ADO.NET provider for MySQL ?

There is the official one from here
http://dev.mysql.com/downloads/connector/net
but unfortunately, it's under the GPL, not the LGPL.

I am developing an abstract class for database access.
I don't care whether the abstraction layer is going to be GPL,
but if it uses MySQL (I mean the MySQL ADO.NET provider, not the MySQL database itselfs) it will be GPL, and thus, any application that uses that layer, which is something I don't want...


Oh, and I know about nHibernate/Subsonic/otherORMs, but it doesn't fit my needs.

ADO.NET provider short of using ODBC of course.

Edit/Clarification:
Note that by "abstract class for database access", I don't mean write my own universal ADO.NET provider. I mean writing a wrapper class around a set of already existing ADO.NET providers.

like image 886
Stefan Steiger Avatar asked Dec 14 '11 11:12

Stefan Steiger


People also ask

Does ADO.NET support MySQL?

The ADO.NET Provider for MySQL offers the most natural way to access MySQL data from any . NET application. Simply use MySQL Data Provider objects to connect and access data just as you would access any traditional database. Our ADO.NET Provider for MySQL gives developers the power to easily connect .

Does .NET work with MySQL?

Connector/NET includes full support for: Features provided by MySQL Server, up to and including the MySQL 8.0 release series. MySQL as a document store (NoSQL), along with X Protocol connection support to access MySQL data using X Plugin ports.

What is MySQL Connectornet?

MySqlConnector is an ADO.NET data provider for MySQL Server, MariaDB, Percona Server, Amazon Aurora, Azure Database for MySQL, Google Cloud SQL for MySQL and more. It provides implementations of DbConnection , DbCommand , DbDataReader , DbTransaction — the classes needed to query and update databases from managed code.

Is C# compatible with MySQL?

Connect C# to MySQLAll the communication between a C# application and the MySQL server is routed through a MySqlConnection Object. So, before your application can communicate with the server, it must instantiate, configure, and open a MySqlConnection object.


2 Answers

There is DevArt's ADO.NET provider for MySQL

http://www.devart.com/dotconnect/mysql/

like image 33
Dani Avatar answered Nov 15 '22 18:11

Dani


I got the perfect answer:

One can use System.Data.Odbc to get around it.
You can always say, it's generic ODBC, has nothing in particular to do with MySQL, easily replacable.
And whatever you put in the connection string is the problem of your customers.
If the SQL that you send over the ODBC connection works in MySQL/MariaDB only, that's regrettable - but no legal problem ;)

Edit - 2016 Update:
You can use the MIT-licensed MySqlConnector for .NET Core (which also works for .NET) https://github.com/mysql-net/MySqlConnector

like image 154
Stefan Steiger Avatar answered Nov 15 '22 18:11

Stefan Steiger