https://docs.microsoft.com/en-us/windows/wsl/install-win10
sudo apt-get install software-properties-common
sudo apt-key adv --recv-keys --keyserver hkp://keyserver.ubuntu.com:80 0xF1656F24C74CD1D8
sudo add-apt-repository 'deb [arch=amd64,arm64,ppc64el] http://mariadb.nethub.com.hk/repo/10.1/ubuntu bionic main'
sudo apt update
sudo apt install mariadb-server
sudo service mysql start
sudo service mysql status
mysql
mysql> SHOW GLOBAL VARIABLES LIKE 'PORT';
Install HeidiSQL on your windows
Try to connect on your server (localhost, port)
if it doesn't work, go back on your ubuntu and type:
mysql
mysql> GRANT ALL PRIVILEGES on *.* to 'root'@'localhost' IDENTIFIED BY '<password>';
mysql> FLUSH PRIVILEGES;
sudo service mysql restart
mysql -u root -p
then type your <password>
If it worked, type your password in HeidiSQL
Create a table on HeidiSQL
go back on your server on Ubutuntu
mysql> use table <your table>
https://mariadb.com/kb/en/data-types/
/!\ Use Pomelo EntityFrameworkCore Package https://docs.microsoft.com/fr-fr/aspnet/core/data/ef-mvc/migrations?view=aspnetcore-3.1
Scaffold-DbContext "server=localhost;user=root;password=admin;database=earlynews_test" Pomelo.EntityFrameworkCore.Mysql -OutputDir DataAccess\EFModels -force