Show all databases
mysql> show databases;
Create Database :
create database cake_blog;
Use Database:
use cake_blog;
CREATE NEW TABLES
Create table posts(
id INT UNSIGNED AUTO_INCREMENT PRIMARY KEY,
title VARCHAR(50),
body TEXT,
created DATETIME DEFAULT NULL,
modified DATETIME DEFAULT NULL);
INSERT DATA
INSERT INTO posts(title,body,created)
VALUES ('The title', 'This is the post body.', NOW());
ALTER TABLE : ADD & DROP COLUMN
ADD COLUMN :
ALTER TABLE users ADD group_id INT(11) NOT NULL;
DROP COLUMN: ALTER TABLE users DROP role;
Show columns from table:
SHOW COLUMNS FROM users;
To discover the character set and collation of a database
Readmore: http://en.wikibooks.org/wiki/MySQL/CheatSheet



