48

I won't release my software source code, and it will be a commercial application. Can I use the MySQL without paying any fee to MySQL? if it is illegal, any alternative database suggest?

DNB5brims
  • 29,344
  • 50
  • 131
  • 195

3 Answers3

37

Yes, and you don't have to release your project's source (but you do have to release any modification you make to MySQL itself (only those not the whole program) if you also release your project in binary form containing the modified MySQL code)

In more simple terms, if you modify MySQL and those modifications end up being distributed in binary form you have to publicly release the aforementioned modifications.

Andreas Bonini
  • 44,018
  • 30
  • 122
  • 156
  • 7
    You know that the MySQL JDBC drivers are GLPv3'ed. That really puts a hamper on using those drivers in a commercial app without paying for their commercial license. – Andrew T Finnell Oct 10 '12 at 15:55
  • So in simple terms, we can use MySql database for our own commercial applications free of cost. Correct me if I'm wrong. – Zameer Ansari Apr 11 '15 at 05:11
  • I have PHP application that uses MySQL and it will run on the client's LAN (Intranet) . I will sale my application and I will prevent (Disallow) modification of the source code nor redistributing it. I just used MySQL as it is. Does your answer apply to this situation too? i.e I don't need commercial licence for the MySQL? – SaidbakR Sep 28 '17 at 15:56
  • 2
    @SaidbakR, yes, you can still use MySQL without worrying about licensing costs. As long as you don't modify the course code of MySQL itself, that is. As an application developer I am guessing that you won't be doing that. So you can safely and freely deploy your program including MySQL on your client's premises. You can both close source and modify your own program, of course, because that's your IP. HTH. – Najeeb Oct 24 '19 at 10:20
24

MySQL itself is open source and can be used as a standalone product in a commercial environment. If you're running mySQL on a web server, you are free to do so for any purpose, commercial or not. If you run a website that uses mySQL, you won't need to release any of your code. You'll be fine.

mySQL has enterprise licenses with (I think) a different code base, and premium support by Sun, but those are entirely optional.

There are limitations on redistribution of mySQL within a closed source product, and linking against mySQL libraries as was pointed out in a different comment. As for redistribution:

OEMs, ISVs, VARs and other distributors that combine and distribute commercially licensed software with MySQL software and do not wish to distribute the source code for the commercially licensed software under version 2 of the GNU General Public License (the "GPL") must enter into a commercial license agreement with Sun.

if you are looking to redistribute mySQL along with a commercial product, check their legal page. I think most companies circumvent this by installing the mySQL server separately.

GPL and linking against client libraries?

I don't know what the fact that the GPL (the license mySQL is distributed under) forbids linking against closed source software means for applications that do not link against mySQL directly, but ship with mySQL client libraries. Do those have to be Open Source? If anybody would like to shed a light on this, in a separate answer or a comment, I'd be most interested.

d512
  • 32,267
  • 28
  • 81
  • 107
Pekka
  • 442,112
  • 142
  • 972
  • 1,088
4

From what I understood:
If you use MySQL "as is" just for the testing purposes - you are free to use it.

If you modify the MySQL

  • you are still free to use it BUT you have to make the modifications you made public
    (GPL is "transfering")

If you redistribute MySQL or work derivated from MySQL in any way, then this says it all:

Q3: As a commercial OEM, ISV or VAR, when should I purchase a commercial license for MySQL software?
A: OEMs, ISVs and VARs that want the benefits of embedding commercial binaries of MySQL software in their commercial applications but do not want to be subject to the GPL and do not want to release the source code for their proprietary applications should purchase a commercial license from Oracle. Purchasing a commercial license means that the GPL does not apply, and a commercial license includes the assurances that distributors typically find in commercial distribution agreements.

jave.web
  • 13,880
  • 12
  • 91
  • 125
  • Does procedures and triggers regarded as modification to the MySQL? – SaidbakR Sep 28 '17 at 15:58
  • 6
    @SaidbakR No, because that is just an SQL, you are not altering the original MySQL code. metaphorically... **Making a popcorn in a microwave does not break your warranty, however messing with the microwave itself does.** – jave.web Sep 28 '17 at 18:49
  • 1
    so if we use MySQL as a DB in our software, and that software is windows desktop application, then we need to buy a commercial license? I guess prior to Oracle this was not the case with MySQL? – kuldeep Dec 11 '17 at 10:05
  • @k2ibegin From what I understood, you either have to make your application GPL or you have to buy commercial license :) Not sure how this was prior to Oracle though :) – jave.web Dec 11 '17 at 17:35