[ת]¹ØÓÚMYSQLµÄshow status½âÏê
¹ØÓÚMYSQLµÄshow status½âÏê
SHOW STATUSÌṩ·þÎñÆ÷µÄ״̬ÐÅÏ¢(Ïómysqladmin extended-statusÒ»Ñù)¡£Êä³öÀàËÆÓÚÏÂÃæµÄÏÔʾ£¬¾¡¹Ü¸ñʽºÍÊý×Ö¿ÉÒÔÓе㲻ͬ£º
+--------------------------+--------+
| Variable_name | Value |
+--------------------------+--------+
| Aborted_clients | 0 |
| Aborted_connects | 0 |
| Connections | 17 |
| Created_tmp_tables | 0 |
| Delayed_insert_threads | 0 |
| Delayed_writes | 0 |
| Delayed_errors | 0 |
| Flush_commands | 2 |
| Handler_delete | 2 |
| Handler_read_first | 0 |
| Handler_read_key | 1 |
| Handler_read_next | 0 |
| Handler_read_rnd | 35 |
| Handler_update | 0 |
| Handler_write | 2 |
| Key_blocks_used | 0 |
| Key_read_requests | 0 |
| Key_reads | 0 |
| Key_write_requests | 0 |
| Key_writes | 0 |
| Max_used_connections | 1 |
| Not_flushed_key_blocks | 0 |
| Not_flushed_delayed_rows | 0 |
| Open_tables | 1 |
| Open_files | 2 |
| Open_streams | 0 |
| Opened_tables | 11 |
| Questions | 14 |
| Slow_queries | 0 |
| Threads_connected | 1 |
| Threads_running | 1 |
| Uptime | 149111 |
+--------------------------+--------+
ÉÏÃæÁгöµÄ״̬±äÁ¿ÓÐÏÂÁк¬Ò壺
Aborted_clients ÓÉÓÚ¿Í»§Ã»ÓÐÕýÈ·¹Ø±ÕÁ¬½ÓÒѾËÀµô£¬ÒѾ·ÅÆúµÄÁ¬½ÓÊýÁ¿¡£
Aborted_connects ³¢ÊÔÒѾʧ°ÜµÄMySQL·þÎñÆ÷µÄÁ¬½ÓµÄ´ÎÊý¡£
Connections ÊÔͼÁ¬½ÓMySQL·þÎñÆ÷µÄ´ÎÊý¡£
Created_tmp_tables µ±Ö´ÐÐÓï¾äʱ£¬ÒѾ±»´´ÔìÁ˵ÄÒþº¬ÁÙʱ±íµÄÊýÁ¿¡£
Delayed_insert_threads ÕýÔÚʹÓõÄÑÓ³Ù²åÈë´¦ÀíÆ÷Ï̵߳ÄÊýÁ¿¡£
Delayed_writes ÓÃINSERT DELAYEDдÈëµÄÐÐÊý¡£
Delayed_errors ÓÃINSERT DELAYEDдÈëµÄ·¢ÉúijЩ´íÎó(¿ÉÄÜÖظ´¼üÖµ)µÄÐÐÊý¡£
Flush_commands Ö´ÐÐFLUSHÃüÁîµÄ´ÎÊý¡£
Handler_delete ÇëÇó´ÓÒ»ÕűíÖÐɾ³ýÐеĴÎÊý¡£
Handler_read_first ÇëÇó¶ÁÈë±íÖеÚÒ»ÐеĴÎÊý¡£
Handler_read_key ÇëÇóÊý×Ö»ùÓÚ¼ü¶ÁÐС£
Handler_read_next ÇëÇó¶ÁÈë»ùÓÚÒ»¸ö¼üµÄÒ»ÐеĴÎÊý¡£
Handler_read_rnd ÇëÇó¶ÁÈë»ùÓÚÒ»¸ö¹Ì¶¨Î»ÖõÄÒ»ÐеĴÎÊý¡£
Handler_update ÇëÇó¸üбíÖÐÒ»ÐеĴÎÊý¡£
Handler_write ÇëÇóÏò±íÖвåÈëÒ»ÐеĴÎÊý¡£&nbs
Ïà¹ØÎĵµ£º
MySQL´æ´¢¹ý³ÌµÄ²ÎÊýÓÃÔÚ´æ´¢¹ý³ÌµÄ¶¨Ò壬¹²ÓÐÈýÖÖ²ÎÊýÀàÐÍ,IN,OUT,INOUT,ÐÎʽÈ磺
CREATE PROCEDURE([[IN |OUT |INOUT ] ²ÎÊýÃû Êý¾ÝÀàÐÎ...])
1¡¢IN ÊäÈë²ÎÊý:±íʾ¸Ã²ÎÊýµÄÖµ±ØÐëÔÚµ÷Óô洢¹ý³Ìʱָ¶¨£¬ÔÚ´æ´¢¹ý³ÌÖÐÐ޸ĸòÎÊýµÄÖµ²»Äܱ»·µ»Ø£¬ÎªÄ¬ÈÏÖµ
2¡¢OUT Êä³ö²ÎÊý:¸ÃÖµ¿ÉÔÚ´æ´¢¹ý³ÌÄÚ²¿±»¸Ä±ä£¬²¢¿É·µ»Ø
3¡¢I ......
ÎÒÓÐÒ»¸ö±í
CREATE TABLE `test1` (
`id` int(10) unsigned NOT NULL AUTO_INCREMENT,
`name` varchar(20) NOT NULL,
`desc` varchar(100) NOT NULL,
PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8
£¨1£©ÒÔϲéѯ»á±¨´íÎó£º[Err] 1221 - Incorrect usage of UNION and ORDE ......
ÔÚMySQL 3.23.44°æ±¾ºó£¬InnoDBÒýÇæÀàÐ͵ıíÖ§³ÖÁËÍâ¼üÔ¼Êø¡£
Íâ¼üµÄʹÓÃÌõ¼þ£º
1.Á½¸ö±í±ØÐëÊÇInnoDB±í£¬MyISAM±íÔÝʱ²»Ö§³ÖÍâ¼ü£¨¾Ý˵ÒÔºóµÄ°æ±¾ÓпÉÄÜÖ§³Ö£¬µ«ÖÁÉÙÄ¿Ç°²»Ö§³Ö£©£»
2.Íâ¼üÁбØÐ뽨Á¢ÁËË÷Òý£¬MySQL 4.1.2ÒÔºóµÄ°æ±¾ÔÚ½¨Á¢Íâ¼üʱ»á×Ô¶¯´´½¨Ë÷Òý£¬µ«Èç¹ûÔÚ½ÏÔçµÄ°æ±¾ÔòÐèÒªÏÔʾ½¨Á¢£»
3.Íâ¼ü¹ØϵµÄÁ½¸ö± ......
½ñÌì¶Áµ½
When should you store serialized objects in the database?
£¬
ÆäÖÐÕë¶Ô
FriendFeedʹÓÃMysqlÀ´´æ´¢
×÷ΪÒýÌ⣬
½¨ÒéÔÚ¿¼ÂÇ´Ë·½°¸Ê±Ò»¶¨ÒªÈý˼¡£ÎªÊ²Ã´£¿²Î¿¼ÕâÀï
Kiss KISS KISS
. Æäʵ
Schema-LessûÓÐ´í£¬µ«²»ÄÜʲô³¡¾°¶¼ÉÏ´Ë·½°¸£¬Òª
·ÖÎöÀû±×£¬¼õÉÙ²»±ØÒªµÄÓ¦Óò㸴ÔӶȡ£
ÎÄÖÐÌáµ½µÄSerializ ......
ÊýÖµÀàÐÍ
¡¡¡¡MySQL µÄÊýÖµÊý¾ÝÀàÐÍ¿ÉÒÔ´óÖ»®·ÖΪÁ½¸öÀà±ð£¬Ò»¸öÊÇÕûÊý£¬ÁíÒ»¸öÊǸ¡µãÊý»òСÊý¡£Ðí¶à²»Í¬µÄ×ÓÀàÐͶÔÕâЩÀà±ðÖеÄÿһ¸ö¶¼ÊÇ¿ÉÓõģ¬Ã¿¸ö×ÓÀàÐÍÖ§³Ö²»Í¬´óСµÄÊý¾Ý£¬²¢ÇÒ MySQL ÔÊÐíÎÒÃÇÖ¸¶¨ÊýÖµ×Ö¶ÎÖеÄÖµÊÇ·ñÓÐÕý¸ºÖ®·Ö»òÕßÓÃÁãÌî²¹¡£
¡¡¡¡±íÁгöÁ˸÷ÖÖÊýÖµÀàÐÍÒÔ¼°ËüÃǵÄÔÊÐí·¶Î§ºÍÕ¼ÓõÄÄÚ´æ¿Õ¼ä¡£
......