Set Password
SET PASSWORD FOR username@localhost=PASSWORD(\'new_password\');
Manipulate the privilege tables
UPDATE user SET Password=PASSWORD(\'new_password\') WHERE user=\'username\';
FLUSH PRIVILEGES;
FLUSH PRIVILEGES;
Backup of MySql databases
mysqldump --tab=/path/to/some/dir --opt --full
Grant Priviledges
grant select,insert,update,delete on test.* to username identified by \'\';
Grant Priviledges
grant select,insert,update,delete on db.* to username@\'192.168.0.1\' identified by \'\';
Create a table with the id column that auto imcrements
create table example(id init auto_imcrement primary key(id));