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

myeclipse mysql²»ÈòåÈëÖÐÎÄ

 Ê×ÏÈ¿´¿´ jspÎļþ java³ÌÐòÀïÓÐûÓÐrequest.setCharacterEncoding("UTF-8");
  ×Ö·û±àÂëÎÊÌ⣬Êý¾Ý²åÈë¿âÖÐʱ£¬java±àÂëºÍÊý¾Ý¿â±àÂë²»Ò»Ö£¬µ¼Ö²åÈëÊý¾Ý¿âΪÂÒÂ룬¿´µ½Îª£¿£¿£¿£¿µÄÐÎʽ  
  ½«ÄãµÄjspÒ³Ãæ±àÂë¸ÄΪGBK£¬Êý¾Ý¿â¶ÔÓ¦±íµÄ±àÂëÒ²¸ÄΪGBK
  ±àÂëÒ»Ö£¬¾Í²»»á³öÏÖÂÒÂëÎÊÌâÁË
×Ö·û±àÂë²»¶Ô ¾Í»áÕâÑùÁË ÄãÔÚ½¨Êý¾Ý¿âµÄʱºò ×îºÃ¼ÓÉÏÕâÑùÒ»¾ä
create database tea default character set utf8 collate utf8_general_ci;
set names 'utf8';
ÕâÊǶÔÊý¾Ý¿âĬÈÏ×Ö·ûµÄÉèÖà ÒÔºó¶ÔÊý¾Ý¿âµÄ²Ù×÷¶¼»áʹÓÃutf8µÄ×Ö·û±àÂë
ÔÚÄãµÄ³ÌÐòÀï Ò²ÒªÊʵ±µÄ¶Ô×Ö·û½øÐд¦Àí ÕâÒª¸ù¾ÝµÄÄã³ÌÐò¶¨ ²»Ò»ÑùµÄ³ÌÐòÐ޸ĵÄÐÎʽ²»Ò»Ñù
ÏñÄãÒÔÇ°ÔÚÃüÁî´°¿ÚÏÂʹÓÃMySQLÎÞ·¨²åÈëÖÐÎľÍÊǵäÐ͵Ä×Ö·û²»¶ÔÔì³ÉµÄ ÄãÔÚ¶ÔÊý¾Ý¿â²Ù×÷֮ǰ ×îºÃÔÚÃüÁî´°¿ÚÉèÖÃһϲÙ×÷ʱµÄ±àÂë
ÀýÈç setchar utf8;
ÕâÑù²åÈëµÄʱºò¾Í²»»á²å²»½øÈ¥ÁË


Ïà¹ØÎĵµ£º

MySQLÐÔÄÜÓÅ»¯

ÔÚApache, PHP, MySQLµÄÌåϵ¼Ü¹¹ÖУ¬MySQL¶ÔÓÚÐÔÄܵÄÓ°Ïì×î´ó£¬Ò²ÊǹؼüµÄºËÐIJ¿·Ö¡£¶ÔÓÚDiscuz!ÂÛ̳³ÌÐòÒ²ÊÇÈç´Ë£¬MySQLµÄÉèÖÃÊÇ·ñºÏÀíÓÅ»¯£¬Ö±½ÓÓ°Ïìµ½ÂÛ̳µÄËٶȺͳÐÔØÁ¿£¡Í¬Ê±£¬MySQLÒ²ÊÇÓÅ»¯ÄѶÈ×î´óµÄÒ»¸ö²¿·Ö£¬²»µ«ÐèÒªÀí½âһЩMySQLרҵ֪ʶ£¬Í¬Ê±»¹ÐèÒª³¤Ê±¼äµÄ¹Û²ìͳ¼Æ²¢ÇÒ¸ù¾Ý¾­Ñé½øÐÐÅжϣ¬È»ºóÉèÖúÏÀíµÄ²ÎÊý¡ ......

MySQLÒýÇæ¼ò½é

MySQLÊÇÎÒÃDZȽϳ£ÓõÄÒ»ÖÖÊý¾Ý
¿âÈí¼þ¡£ËüÓÐ×ÅÖî¶àµÄÓŵ㣬È翪ԴµÄ£¬Ãâ·ÑµÄµÈµÈ¡£ÆäʵËü»¹ÓÐÒ»¸öºÜºÃµÄÌص㣬ÄǾÍÊÇÓжàÖÖÒýÇæ¿ÉÒÔ¹©ÄãÑ¡Ôñ¡£Èç¹ûÈü
³µÊÖÄܸù¾Ý²»Í¬µÄ·¿ö£¬µØÐÎËæÊÖ¸ü»»ÓëÖ®×îÊÊÒ˵ÄÒýÇ棬ÄÇôËûÃǽ«´´ÔìÆæ¼£¡£È»¶øÄ¿Ç°ËûÃÇ»¹×ö²»µ½ÄÇÑù±ã½ÝµÄ¸ü»»ÒýÇ棬µ«ÊÇÎÒÃÇÈ´¿ÉÒÔ£¡
     Ëù ......

MySQL¸ßЧÔËÐбر¸£º¼òµ¥µÄ֪ʶ½ÌÄã¸ßЧÔËÓÃË÷Òý

ÔÚÊý¾Ý¿â±íÖУ¬¶Ô×ֶν¨Á¢Ë÷Òý¿ÉÒÔ´ó´óÌá¸ß²éѯËٶȡ£¼ÙÈçÎÒÃÇ´´½¨ÁËÒ»¸ö mytable±í£º
CREATE TABLE mytable(
ID INT NOT NULL,
username VARCHAR(16) NOT NULL
);
ÎÒÃÇËæ»úÏòÀïÃæ²åÈëÁË10000Ìõ¼Ç¼£¬ÆäÖÐÓÐÒ»Ìõ£º5555, admin¡£
ÔÚ²éÕÒusername="admin"µÄ¼Ç¼ SELECT * from mytable WHERE username='admin';ʱ£¬Èç¹ ......

mysqlÃüÁ½õ

¡¾×¢£º¿ÉÒÔÔÚmysqlÖÐͨ¹ýmysql> SELECT VERSION();À´²é¿´Êý¾Ý¿â°æ±¾¡¿
ÕûÀí£ºleo
Ò»¡¢Á¬½ÓMYSQL¡£
¸ñʽ£º mysql -hÖ÷»úµØÖ· -uÓû§Ãû £­pÓû§ÃÜÂë
1¡¢Á¬½Óµ½±¾»úÉϵÄMYSQL¡£
Ê×ÏÈ´ò¿ªDOS´°¿Ú£¬È»ºó½øÈëĿ¼mysql\bin£¬ÔÙ¼üÈëÃüÁîmysql -u root -p£¬»Ø³µºóÌáʾÄãÊäÃÜÂë.×¢ÒâÓû§ÃûÇ°¿ÉÒÔÓпոñÒ²¿ÉÒÔûÓпոñ£¬µ«ÊÇà ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ