mysql
create database if not exists database_name;
show databases;
use database_name;
drop database if exists database_name;
create table table_name(
column_name data_type(size) [NOT] NULL,
.
primary key(col_name)
);
show tables;
describe table_name;
drop table table_name;
truncate table table_name;
alter table table_name
select column_name1,column_name2,...
from tables
[where condition="conditions"]
[group BY group
[having group_conditions]]
[order BY sort_columns]
[limit limits];
select distinct column_name from tables;
select count(*), column_name from table_name group by column_name;
select count(*), column_name from table_name group by column_name having count(*)=1;
select column1,column2 from table_name order by column1 asc, column2 desc;
select column1,column2 from table_name where column1like' '
select column1,column2 from table_name1 union select column1,column2 from table_name2