=======================
INSTALL AND START MYSQL SERVER
1 st step is to install the MySQL Server, it is easy to perform on Ubuntu:
sudo apt-get install mysql-server
2: start the service:
sudo /etc/init.d/mysql start
3: login:
mysql -u root -p
and then, enter your password.
==========================
TO USE MYSQL SERVER WITH JAVA
you have to download lib file called connector:
you can find more versions here.
when you compile the Java program, you have to include this connector file in the classpath variable;
If you use eclipse, you can include this file by selecting the project->properties->Java Build Path->Libraries->Add External Library.
==========================
SOME USEFUL SQL COMMANDS
check all available databases:
mysql>show databases;
use a database:
mysql>use database_name;
check all tables in this database:
mysql>show tables;
delet a table in a database:
mysql>drop table table_name;
a
==========================
INSTALL AND START MYSQL SERVER
1 st step is to install the MySQL Server, it is easy to perform on Ubuntu:
sudo apt-get install mysql-server
2: start the service:
sudo /etc/init.d/mysql start
3: login:
mysql -u root -p
and then, enter your password.
==========================
TO USE MYSQL SERVER WITH JAVA
you have to download lib file called connector:
you can find more versions here.
when you compile the Java program, you have to include this connector file in the classpath variable;
If you use eclipse, you can include this file by selecting the project->properties->Java Build Path->Libraries->Add External Library.
==========================
SOME USEFUL SQL COMMANDS
check all available databases:
mysql>show databases;
use a database:
mysql>use database_name;
check all tables in this database:
mysql>show tables;
delet a table in a database:
mysql>drop table table_name;
a
==========================