Google+ Followers

Connect

Get Updates Via Email

Enter your email address:

Delivered by FeedBurner

Saturday, 16 November 2013

MySql linux terminal Commands: Basic commands to create and drop databases commands

1. Login on mysql  command



mysql -u root -h localhost -p








2. Check Status

mysql> status










3. show databases

mysql> show databases;














4. Show variables

mysql> show variables;



5. Show processlist

mysql> show processlist;



6. Using and selecting system already available mysql database

mysql> use mysql;
mysql> select database();


7. select user table in mysql database

mysql> select Host, User from user
or

mysql> select Host, User from mysql.user



8. Create database and display it

mysql> create database tempDB;
mysql> show databases;
mysql> use tempDB;
mysql> select database();



9. Drop database

 mysql> drop database tempDB;
 mysql> show databases;



10. exit  mysql 

 mysql> exit


 

1 comment :

  1. I have read your blog its very attractive and impressive. I like it your blog.

    Java Online Training Java EE Online Training Java EE Online Training Java 8 online training Core Java 8 online training

    Java Online Training from India Java Online Training from India Core Java Training Online Core Java Training Online Java Training InstitutesJava Training Institutes

    ReplyDelete

Share this to your friends