Connecting to a MariaDB/MySQL using Java



Connecting to a MariaDB/MySQL using Java

Connecting to a MariaDB/MySQL using Java

This video explains all the process to connect to MariaDB o MySQL database. The video is divided in different parts:

1.- Installing MariaDB service
2.- Creating a database and a table.
3.- Creating an user. This user will be used to connect to the database. This way, the user has limited rights on the server.
4.- Assign create, select, update and delete rights to the new created user. These are the only operations available to the user.
5.- Download and install Java connector
6.- Create a new Java console project. I’m using tje IntellJ IDE.
7.-. Add MySQL connector class to the project.
8.- Test the connection.
9.- Retrieve some records from the table