ʹÓÃmysqlµÄreplaceº¯ÊýÌæ»»×Ö·û´®
×î½üÔÚÑо¿CMS£¬ÔÚÊý¾Ýת»»µÄʱºòÐèÒªÓõ½mysqlµÄreplaceº¯Êý£¬ÕâÀï¼òµ¥½éÉÜһϣ¡
±ÈÈçÄãÒª½« ±í tb1ÀïÃæµÄ f1×ֶεÄabcÌ滻Ϊdef
UPDATE tb1 SET f1=REPLACE(f1, 'abc', 'def');
REPLACE(str,from_str,to_str)
ÔÚ×Ö·û´® str ÖÐËùÓгöÏÖµÄ×Ö·û´® from_str ¾ù±» to_strÌæ»»£¬È»ºó·µ»ØÕâ¸ö×Ö·û´®£º
mysql> SELECT REPLACE('www.mysql.com', 'w', 'Ww');
-> 'WwWwWw.mysql.com'
Õâ¸öº¯ÊýÊǶà×Ö½Ú°²È«µÄ¡£
ʾÀý£º
UPDATE `dede_addonarticle` SET body = REPLACE ( body,
'</td>',
'' );
UPDATE `dede_addonarticle` SET body = REPLACE ( body,
'</tr>',
'' );
UPDATE `dede_addonarticle` SET body = REPLACE ( body,
'<tr>',
'' );
UPDATE `dede_archives` SET title= REPLACE ( title,
'´óÑóÐÂÎÅ - ',
'' );
UPDATE `dede_addonarticle` SET body = REPLACE ( body,
'../../../../../../',
'http://special.dayoo.com/meal/' );
mysql replace
Ó÷¨1.replace intoreplace into table (id,name) values(‘1‘,‘aa‘),(‘2‘,‘bb‘)
´ËÓï¾äµÄ×÷ÓÃÊÇÏò±ítableÖвåÈëÁ½Ìõ¼Ç¼¡£
2.replace(object, search,replace)
°ÑobjectÖгöÏÖsearchµÄÈ«²¿Ì滻Ϊreplaceselect replace(‘www.163.com‘,‘w‘,‘Ww‘)--->WwW wWw.163.com
Àý£º°Ñ±ítableÖеÄname×Ö¶ÎÖÐµÄ aaÌ滻Ϊbbupdate table set name=replace(name,‘aa‘,‘bb‘)
Ïà¹ØÎĵµ£º
http://www.cnblogs.com/rethink/archive/2009/10/09/1579634.html
mysql cache¹¦ÄÜ·ÖÎö£º
1
mysqlµÄcache¹¦ÄܵÄkeyµÄÉú³ÉÔÀíÊÇ£º°ÑselectÓï¾ä°´ÕÕÒ»¶¨µÄhash¹æÔòÉú³ÉΨһµÄkey£¬selectµÄ½á¹ûÉú³Évalue£¬¼´key=>value¡£ËùÒÔ¶ÔÓÚcache¶øÑÔ£¬selectÓï¾äÊÇÇø·Ö´óСдµÄ£¬Ò²Çø·Ö¿Õ¸ñµÄ¡£Á½¸öselectÓï¾ä±ØÐëÍêÍêÈ«È«Ò»Ö ......
ʹÓÃÕûÊýÊý¾ÝµÄ¾«È·Êý×ÖÊý¾ÝÀàÐÍ¡£
bigint
´Ó -2^63 (-9223372036854775808) µ½ 2^63-1 (9223372036854775807) µÄÕûÐÍÊý¾Ý£¨ËùÓÐÊý×Ö£©¡£´æ´¢´óСΪ 8 ¸ö×Ö½Ú¡£
int
´Ó -2^31 (-2,147,483,648) µ½ 2^31 - 1 (2,147,483,647) µÄÕûÐÍÊý¾Ý£¨ËùÓÐÊý×Ö£©¡£´æ´¢´óСΪ 4 ¸ö×Ö½Ú¡£int µÄ SQL-92 ͬÒå×ÖΪ integer¡£
smallin ......
¡¡¡¡ÊÂÎñÊÇDBMSµÃÖ´Ðе¥Î»¡£ËüÓÉÓÐÏÞµÃÊý¾Ý¿â²Ù×÷ÐòÁÐ×é³ÉµÃ¡£µ«²»ÊÇÈÎÒâµÃÊý¾Ý¿â²Ù×÷ÐòÁж¼ÄܳÉΪÊÂÎñ¡£Ò»°ãÀ´Ëµ£¬ÊÂÎñÊDZØÐëÂú×ã4¸öÌõ¼þ£º£¨ACID£©
¡¡¡¡Ô×ÓÐÔ£¨Autmic£©£ºÊÂÎñÔÚÖ´ÐÐÐÔ£¬Òª×öµ½“Ҫô²»×ö£¬ÒªÃ´È«×ö£¡”£¬¾ÍÊÇ˵²»ÔÊÐíÊÂÎñ²¿·ÖµÃÖ´ÐС£¼´Ê¹ÒòΪ¹ÊÕ϶øʹÊÂÎñ²»ÄÜÍê³É£¬ÔÚrollbackʱҲҪÏû³ý¶ÔÊ ......
mysql tomcat Too many open files in system
1. MySQL:Too many open files in system
À´Ô´£ºhttp://phorum.study-area.org/index.php?topic=10819.0
¡ù ÒýÊö¡¶jacinth.bbs@bbs.cs.nthu.edu.tw (ó¯òë)¡·Ö®銘ÑÔ£º
> hi¸÷λ
> ÎÒµÄϵ統Ö÷ÒªÅÜwww+php+mysql
> Óв»ÉÙÈËÔÚʹÓÃ
> 這 ......
µÃ°²ÆæרÂô£¨Ô˶¯ÐÝÏÐЬ£¬°åЬ£©ÌÔ±¦Ð¡µê£ºwww.bxbshoes.com
substring£º
Óï·¨
SUBSTRING ( expression , start , length )
²ÎÊý
expression
ÊÇ×Ö·û´®¡¢¶þ½øÖÆ×Ö·û´®¡¢text¡¢image¡¢Áлò°üº¬Áеıí´ïʽ¡£²»ÒªÊ¹Óðüº¬¾ÛºÏº¯ÊýµÄ ......