Click here to Skip to main content
15,112,662 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hi,
My c# Project work with MySQL, and i have installed it on my customers devices (50 customer => 80 device ((1 or 2 device for every customer)) (windows 7,8,10))
it work with MySQL Server 5.7.21.

this days I update the project to work with MySQL 8 (MySQL Server 8.0.18).

What I have tried:

I already created class to check if there any new versions and download the new files of the project from my website. but what i can't do it :
1- check the current version of MySQL Server ( that run the service "custom name").
2- if found it 5.7.21 auto update the MySQL Server to 8.0.18 without losing the database.
3- i need to do that in background by code or any another approach because the customer didn't know how to update MySQL Server also it is very difficult to manual update or reinstall it in 80 device).
Posted
Updated 12-Apr-21 2:59am
v2

1 solution

The whole idea of MySql and SQL Server is that you don't "install it on 80 devices" - you install it on one device that all the client computers can reach, and let it handle the database. Your clients connect to that one instance, and share the DB between them.

Thus, updating the DB requires installation of the new version on a single computer, no changes should be necessary to any of the clients (unless the new installation requires a change to the connection string, and that should be just an update to a configuration file unless your app is very badly written).

Don't even try to install a DB server system through yoru code: it requires access to the host machine at admin level to do the upgrade and your software should very much not have that access at all for security reasons.
   
Comments
Golden Basim 12-Apr-21 8:07am
   
50 customer not 1 CUSTOMER. every customer have different company and in different location. every location work locally (there are some customer already have to devices connected together as you mentioned).

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)




CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900