Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

¹ØÓÚMySQL±íÉè¼ÆÓ¦¸Ã×¢ÒâµÄÎÊÌâ

¹ØÓÚMySQL±íÉè¼ÆÓ¦¸Ã×¢ÒâµÄÎÊÌâ
ת×Ô http://blog.chinaunix.net/u/29134/showart_1316574.html
1¡¢É÷ÖØÑ¡Ôñ±íÃû¡£
ÓÐÁ½ÖÖÑ¡Ôñ£º
°´ÕÕ¶àÊý¿ª·¢ÓïÑÔµÄÃüÃû¹æÔò¡£±ÈÈ磨myCustomer£©¡£
°´ÕÕ¶àÊý¿ªÔ´Ë¼ÏëÃüÃû¹æÔò¡£±ÈÈ磨my_customer£©¡£
°´ÕÕÔÛÃÇÖйúÈ˵Ä˼Ïë¡£±ÈÈ磨ÎҵĿͻ§£©¡£
µÚÒ»ÖÖÓиöȱµã£¬ºÜÈÝÒ×Íüµô´óдµÄ×Öĸ¡£
µÚ¶þÖÖÔò±È½ÏºÃ£¬Ã¿¸öWORD¼äÓÃÏ»®ÏßÁ¬½Ó£¬±ÜÃâÒÅÍü¡£
µÚÈýÖÖ½¨Òé²»ÒªÓã¬ËäÈ»ºÜºÃ¼Ç¡£²»¾õµÃ½âÎöÕâ¸ö±íµÄʱºò»¹ÐèÒª±àÂëת»¯Âð£¿ÎÒ¸öÈËÀí½â£¬´ó¼Ò¿ÉÒÔ²¹³ä¡£
2.¹ØÓÚ±àÂëµÄÉ趨¡£ 
A£®             GBK/GB2312.£¨ÊÊÓÃÓÚ´¿ÖÐÎÄ´æ´¢£©¡£
B£®           UTF8.£¨ÊÊÓÃÓÚÖÐÓ¢ÎÄ»ìºÏ´æ´¢£©¡£
C£®            LATIN1¡££¨ÊÊÓÃÓÚ´¿Ó¢ÎÄ´æ´¢£©¡£
D.     ÆäËûµÄ¡£
3.¹ØÓÚ±íÒýÇæµÄÑ¡Ôñ¡£ 
A.                 MYISAM.£¨ºÜ¶àÈË˵ËýµÄ±í¼¶Ëø¶¨»á´øÀ´ºÃ¶àÎÊÌ⣬ÆäʵֻҪÉè¼ÆºÃ¶ÔÓ¦µÄ±íÒÔ¼°Ð´ºÃ¶ÔÓ¦µÄSQL²éѯ¾ÍûÓÐÄÇô´óµÄÎÊÌâ¡££©
B.                  INNODB. £¨Èç¹ûÒªÓõ½ÊÂÎñ£¬Ñ¡ÔñËý²»»á´í¡£ÖÁÓÚ¶àÊýÈ˽²µÄMASTER/SLAVE½á¹¹ÉÏÓÃINNODBÔÚMASTERµÄÑ¡ÔñÊÇ·ñÕýÈ·£¬¾ÍÒª¿´ÄãÔõôÓÃÁË¡£²»ÄÜһζµÄ·è¿ñʹÓÃINNODB¡£³ý·ÇÄãÏëҪȷ±£·Ç³£¸ß¿ÉÓÃÐÔ£¬
£©
C.                  CSV. £¨ÒÔÇ°ÎÒд¹ýÎÄÕ£¬¹ØÓÚÕâ¸öÒýÇæ¡£¸öÈ˾õµÃ×îÖ÷ÒªµÄÊÇÀ´´æ´¢ÉÙÁ¿Êý¾ÝÒÔ¼°´ÓEXCELµ½MYSQLµÄת»»·½Ãæ»áºÜÓÐÓᣵ±È»Ö»ÒªÉæ¼°µ½¹æÔòÊý¾ÝµÄµ¼È룬Ëý¾Í¿ÉÒÔ°ìµ½¡££©
D.                  BLACKHOLE. £¨¾õµÃ×îÍêÃÀµÄÓô¦ÔÚÓÚMASETR/SLAVEÉÏÃ棬²¢ÇÒMASTERÊÇÒ»¸öÁÙʱµÄרߺÔðдµÄ»úÆ÷¡£²»¹ýȱµãÒ²ºÜ¶à£¬»áÓëMYISAM»òÕßINNODB»òÕßÆäËûµÄÒýÇæÓÐËù³åÍ»£¬Õâµã×Ô¼ºÒª×ö¸öȨºâ£©¡£
E.             


Ïà¹ØÎĵµ£º

mysql´æ´¢¹ý³Ì

mysql> show databases;
+--------------------+
| Database           |
+--------------------+
| information_schema |
| mysql              |
| test     &n ......

MySqlµÄ¸÷ÖÖÒýÇæ

1.MemoryÒýÇæ,ÌṩÄÚ´æ±í
   MySql Memory´æ´¢ÒýÇ棨ÀÏ°æ±¾Ò²½Ð×öheap´æ´¢ÒýÇ棩£¬¹ËÃû˼ÒåÊÇÔÚÄÚ´æÖд洢ËùÓеÄÊý¾Ý£¬Ëü¾ßÓÐÒÔÏÂÁ½¸öÃ÷ÏÔÌØÕ÷£º   
      ¢ÙÄÚ´æÖд洢Êý¾Ý£¬·Ç³£¸ßËÙ;
      ¢Úmysql¹Ø±ÕºóËùÓÐÊý¾ÝÏûʧ£¬mysqlÆô¶¯Ê±»á´´ ......

MYSQL»ù´¡Ö®Á¬½ÓMYSQL¡¢ÐÞ¸ÄÃÜÂë¡¢Ìí¼ÓÓû§

Ò»¡¢Á¬½ÓMYSQL¡£
¸ñʽ£º mysql -hÖ÷»úµØÖ· -uÓû§Ãû £­pÓû§ÃÜÂë
1¡¢Àý1£ºÁ¬½Óµ½±¾»úÉϵÄMYSQL¡£
Ê×ÏÈÔÚ´ò¿ªDOS´°¿Ú£¬È»ºó½øÈëĿ¼ mysqlbin£¬ÔÙ¼üÈëÃüÁîmysql -uroot -p£¬»Ø³µºóÌáʾÄãÊäÃÜÂ룬Èç¹û¸Õ°²×°ºÃMYSQL£¬³¬¼¶Óû§rootÊÇûÓÐÃÜÂëµÄ£¬¹ÊÖ±½Ó»Ø³µ¼´¿É½øÈëµ½MYSQLÖÐÁË£¬MYSQLµÄÌáʾ·ûÊÇ£ºmysql>
2¡¢Àý2£ºÁ ......

½â¾öMySQL²»ÔÊÐí´ÓÔ¶³Ì·ÃÎʵķ½·¨

½â¾ö·½·¨£º
1¡£ ¸Ä±í·¨¡£
¿ÉÄÜÊÇÄãµÄÕʺŲ»ÔÊÐí´ÓÔ¶³ÌµÇ½£¬Ö»ÄÜÔÚlocalhost¡£Õâ¸öʱºòÖ»ÒªÔÚlocalhostµÄÄÇ̨µçÄÔ£¬µÇÈëmysqlºó£¬¸ü¸Ä "mysql" Êý¾Ý¿âÀïµÄ "user" ±íÀïµÄ "host" Ï´Ó"localhost"¸Ä³Æ"%"
mysql -u root -p vmware mysql>use mysql;
mysql>update user set host = '%' where user = 'root';
mys ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ