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

mysql concat Ë÷ÒýÎÊÌâ

hi,all:
ÎÊÌâÃèÊö,ÎÒÓÐÒ»¸ö±ís£¬Á½¸ö×Ö¶Îf,a ¡£´´½¨ÁËÒ»¸öindex(f,a)
µ±ÎÒʹÓÃwhere concat(f,a)= '0033';×ßË÷Òý

µ«ÊÇ£¬Èç¹ûÎÒÈñíÖÐÔÙ¼ÓÒ»¸ö×Ö¶Îb
´Ëʱ£¬ÎÒÔÙʹÓÃwhere concat(f,a)= '0033';ÎÞÂÛÈçºÎÒ²²»×ßË÷ÒýÁË

PS:where concat(f,cast(a,char))= '0033'; ÊÔ¹ýÒ²²»×ß

mysql> show create table s;
+-------+-----------------------------------------------------------------------
--------------------------------------------------------------------------------
+
| Table | Create Table

|
+-------+-----------------------------------------------------------------------
--------------------------------------------------------------------------------
+
| s    | CREATE TABLE `s` (
  `f` varchar(10) NOT NULL DEFAULT '',
  `a` int(4) DEFAULT NULL,
  KEY `idx_f_a` (`f`,`a`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1 |
+-------+-----------------------------------------------------------------------
--------------------------------------------------------------------------------
+
1 row in set (0.00 sec)

mysql> explain select * from s where concat(f,a)= '0033';
+----+-------------+-------+-------+---------------+---------+---------+------+-
-----+--------------------------+
| id | select_type | table | type  | pos


Ïà¹ØÎÊ´ð£º

MYSQL°²×°Ê§°Ü

ÎÒÒÔǰ°²×°ÁËÒ»´Î£¬ºóÀ´Ð¶ÔØÁË£¬ÏÖÔÚÔÙ°²×°µÄʱºò£¬Ìáʾ´íÎó£ºError 1305.Error reading from file C:DOCUME~1\LOCALS~1\Temp\mysql_server.msi.Verify that the file exists and that you can access it. 
¿ ......

mysqlµÄÇý¶¯³ÌÐò

ÎÒÓÐÒ»¸öjava»·¾³ÏµijÌÐò£¬ÔÚ±¾»úÔËÐÐÕý³££¬µ«·¢²¼µ½ÍøµÄÐéÄâÖ÷»úʱ²»ÄÜÁ¬½ÓÊý¾Ý¿âÁ¬½Ó³Ø
jdk 1.6 tomcat6.0.18 mysql5 mysqljdbc5.1.5
ÐéÄâÖ÷»úµÄ¼¼ÊõÈËԱ˵£¬Ö»ÄÜÅäÖþÖÓòµÄÊý¾Ý¿âÁ¬½Ó³Ø£¬Ò²¾ÍÊÇÔÚM ......

MYSQL°²×°Ê§°Ü

ÎÒÒÔǰ°²×°ÁËÒ»´Î£¬ºóÀ´Ð¶ÔØÁË£¬ÏÖÔÚÔÙ°²×°µÄʱºò£¬Ìáʾ´íÎó£ºError 1305.Error reading from file C:DOCUME~1\LOCALS~1\Temp\mysql_server.msi.Verify that the file exists and that you can access it.
¿ÉÊÇÎÒÕÒ ......

mysqlÄ£ºý²éѯÈçºÎ²éѯÁ½¸ö¹Ø¼ü×Ö

ÎÒÓõÄlikeÄ£ºý²éѯ£¬±ÈÈçmysqlµÄnameÖÐÓС°csdnÂÛ̳ϵͳ¡±Õ⼸¸ö×Ö£¬ÈçºÎÔÚ <input>Öвéѯ¡°csdn ϵͳ¡±Ò²ÄܳöÀ´Õâ¸ö¡°csdnÂÛ̳ϵͳ¡±£¬ÎÒÏÖÔÚÊDz顰csdn¡±»òÕß¡°ÏµÍ³¡±¶¼¿ÉÒÔ¡£Ð»Ð»¸÷λÁË£¡²»ÖªµÀÎÒÕâô±í´ï ......

mysql insertÓï¾äÖÐÓÐ?£¬ÌáʾÖÂÃü´íÎ󣿣¿£¿£¿£¿£¿£¿

mysql insertÓï¾äÖÐÓÐ?£¬ÌáʾÖÂÃü´íÎ󣿣¿£¿£¿£¿£¿£¿
¡¡´úÂ룿

ÒýÓÃ
mysql insertÓï¾äÖÐÓÐ?£¬ÌáʾÖÂÃü´íÎ󣿣¿£¿£¿£¿£¿£¿



½¨ÒéÌùÍêÕûinsert´úÂë¼°´íÎó´úÂ룬ÒÔ±ã·ÖÎö

ÇëÂ¥Ö÷ÌùÍêÕûµÄsql´ú ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ