mysql database operations common sql statement

1. Check Create Create a database statement

show create database mysql

The sql statement meant to show the statement to create a database called mysql. After performing shown below

 

 The above statement creates counterfeit create a new database called zj shown below

 In order to prevent the database name to be created already exists may use create database if not exists database name;

 Select database query the database currently in use ();

 Using the use database statement indicates that the file name using a database, it is conceivable to enter the database represents the folder in the following figure

 

Guess you like

Origin www.cnblogs.com/wholeworld/p/11546481.html