MySQL cmdÃüÁî
Á¬½Ó£ºmysql -hÖ÷»úµØÖ· -uÓû§Ãû £pÓû§ÃÜÂë £¨×¢:uÓëroot¿ÉÒÔ²»Óüӿոñ£¬ÆäËüÒ²Ò»Ñù£©
¶Ï¿ª£ºexit £¨»Ø³µ£©
´´½¨ÊÚȨ£ºgrant select on Êý¾Ý¿â.* to Óû§Ãû@µÇ¼Ö÷»ú identified by \"ÃÜÂë\"
ÐÞ¸ÄÃÜÂ룺mysqladmin -uÓû§Ãû -p¾ÉÃÜÂë password ÐÂÃÜÂë
ɾ³ýÊÚȨ: revoke select,insert,update,delete om *.* from test2@localhost;
ÏÔʾÊý¾Ý¿â£ºshow databases;
ÏÔʾÊý¾Ý±í£ºshow tables;
ÏÔʾ±í½á¹¹£ºdescribe ±íÃû;
´´½¨¿â£ºcreate database ¿âÃû;
ɾ³ý¿â£ºdrop database ¿âÃû;
ʹÓÿ⣺use ¿âÃû;
´´½¨±í£ºcreate table ±íÃû (×Ö¶ÎÉ趨Áбí);
ɾ³ý±í£ºdrop table ±íÃû;
ÐÞ¸Ä±í£ºalter table t1 rename t2
²éѯ±í£ºselect * from ±íÃû;
Çå¿Õ±í£ºdelete from ±íÃû;
±¸·Ý±í: mysqlbinmysqldump -h(ip) -uroot -p(password) databasename tablename > tablename.sql
»Ö¸´±í: mysqlbinmysql -h(ip) -uroot -p(password) databasename tablename < tablename.sql£¨²Ù×÷ǰÏȰÑÔÀ´±íɾ³ý£©
Ôö¼ÓÁУºALTER TABLE t2 ADD c INT UNSIGNED NOT NULL AUTO_INCREMENT,ADD INDEX (c);
ÐÞ¸ÄÁУºALTER TABLE t2 MODIFY a TINYINT NOT NULL, CHANGE b c CHAR(20);
ɾ³ýÁУºALTER TABLE t2 DROP COLUMN c;
±¸·ÝÊý¾Ý¿â£ºmysql\bin\mysqldump -h(ip) -uroot -p(password) databasename > database.sql
»Ö¸´Êý¾Ý¿â£ºmysql\bin\mysql -h(ip) -uroot -p(password) databasename < database.sql
¸´ÖÆÊý¾Ý¿â£ºmysql\bin\mysqldump --all-databases > all-databases.sql
ÐÞ¸´Êý¾Ý¿â£ºmysqlcheck -A -o -uroot -p54safer
Îı¾Êý¾Ýµ¼È룺 load data local infile \"ÎļþÃû\" into table ±íÃû;
Êý¾Ýµ¼Èëµ¼³ö£ºmysql\bin\mysqlimport database tables.txt
Ïà¹ØÎĵµ£º
mysqlµÄÊý¾Ý´¢´æÄ¿Â¼ÔÚmysqlµÄÅäÖÃÎļþmy.iniÎļþÉèÖ㬸ñʽÈçÏ£º
# Uncomment the following rows if you move the MySQL distribution to another
# location
basedir = d:/cyoa/mysql_cy/
datadir = d:/cyoa/mysql_cy/data/
ÆäÖÐdatadirĿ¼¶¨ÒåÁËmysqlµÄÊý¾Ý´æ´¢Î»Öã¬MySQLµÄÿ¸ ......
2.»·¾³ËµÃ÷
2.1 Ó²¼þ»·¾³(Á½Ì¨»úÆ÷µÄÓ²¼þ»·¾³Ïàͬ)
CPU
Inter(R) Pentium(R) Dual CPU E5200 @2.50GHz
ÄÚ´æ´óС
384MB
Ó²ÅÌ´óС
8GB
ÆäËü˵Ã÷
±¾»úÆ÷ΪÐéÄâ»ú£¬ÆäÓÐÁ½¿éÍø¿¨£¬Ò»¶ÔÍø¿¨Ö±Á¬£¬Ò»¶Ô½ÓÈë½»»»»ú
CPU
Inter(R) Pentium(R) Dual CPU E5200 @2.50GHz
ÄÚ´æ´óС
384MB
......
´æ´¢¹ý³ÌÊÇÒ»ÖÖ´æ´¢ÔÚÊý¾Ý¿âÖеijÌÐò£¨¾ÍÏñÕý¹æÓïÑÔÀïµÄ×Ó³ÌÐòÒ»Ñù£©£¬×¼È·µÄÀ´Ëµ£¬MySQLÖ§³ÖµÄ“routines£¨Àý³Ì£©”ÓÐÁ½ÖÖ£ºÒ»ÊÇÎÒÃÇ˵µÄ´æ´¢¹ý³Ì£¬ ¶þÊÇÔÚÆäËûSQLÓï¾äÖпÉÒÔ·µ»ØÖµµÄº¯Êý£¨Ê¹ÓÃÆðÀ´ºÍMysqlÔ¤×°ÔØµÄº¯ÊýÒ ......
MySqlѧϰ±Ê¼Ç MySql¸ÅÊö£ºMySqlÊÇÒ»¸öÖÖ¹ØÁªÊý¾Ý¿â¹ÜÀíϵͳ£¬Ëùν¹ØÁªÊý¾Ý¿â¾ÍÊǽ«Êý¾Ý±£´æÔÚ²»Í¬µÄ±íÖУ¬¶ø²»Êǽ«ËùÓÐÊý¾Ý·ÅÔÚÒ»¸ö´óµÄ²Ö¿âÖС£ÕâÑù¾ÍÔö¼ÓÁËËÙ¶ÈÓëÌá¸ßÁËÁé»îÐÔ¡£²¢ÇÒMySqlÈí¼þÊÇÒ»¸ö¿ª·ÅÔ´ÂëÈí¼þ¡£ ×¢Ò⣬MySqlËùÖ§³ÖµÄTimeStampµÄ×î´ó·¶Î§µÄÎÊÌ⣬ÔÚ32λ»úÆ÷ÉÏ£¬Ö§³ÖµÄȡֵ·¶Î§ÊÇÄê·Ý×îºÃ²»Òª³¬¹ý2030Äê ......
²âÊÔ»·¾³£ºmysql 5.0.45 ¡¾×¢£º¿ÉÒÔÔÚmysqlÖÐͨ¹ýmysql> SELECT VERSION();À´²é¿´Êý¾Ý¿â°æ±¾¡¿ÕûÀí£ºWebjx.Com Ò»¡¢Á¬½ÓMYSQL¡£¸ñʽ£º mysql -hÖ÷»úµØÖ· -uÓû§Ãû £pÓû§ÃÜÂë 1¡¢Á¬½Óµ½±¾»úÉϵÄMYSQL¡£Ê×ÏÈ´ò¿ªDOS´°¿Ú£¬È»ºó½øÈëĿ¼mysql\bin£¬ÔÙ¼üÈëÃüÁîmysql -u root -p£¬»Ø³µºóÌáʾÄãÊäÃÜÂë.×¢ÒâÓû§Ãûǰ¿ÉÒÔÓпոñ ......