mysqlÊý¾Ýµ¼³öµ½sqlserver·½·¨
ÕâÀïÊÇʹÓÃODBCÀ´×ª»»Êý¾Ý¿âµÄ¡£
1.°²×°mysqlÊý¾Ý¿âµÄODBCÇý¶¯£¬mysql¹ÙÍøÓÐÏÂÔØhttp://dev.mysql.com/downloads/connector/odbc/
2.´ò¿ª¿ØÖÆÃæ°å\¹ÜÀí¹¤¾ß\Êý¾ÝÔ´ODBC£¬ÔÚÓû§DSNÖÐÌí¼ÓÒ»¸öMySQL ODBC Êý¾ÝÔ´¡£
3.½Ó×ÅÔÚÏÂÃæµÄ´°ÌåÖÐÊäÈëÊý¾ÝÔ´Ãû³Æ£¬Èçmysqlodbc£»È»ºóÊäÈë·þÎñÆ÷ServerµØÖ·£¨localhost»òÆäËû£©£¬Óû§User£¬ÃÜÂëPassword£¬ÊäÈëÕýÈ·ºóÑ¡ÔñÒªµ¼ÈëµÄÊý¾Ý¿â¡£ÔÚÁ¬½ÓÑ¡Ïîconnect optionsÖиù¾ÝÐèÒªÉèÖÃMySqlʹÓõĶ˿ÚportºÍ×Ö·û¼¯Character Set¡£ ×Ö·û¼¯Ò»¶¨ÒªºÍMysql·þÎñÆ÷Ïà¶ÔÓ¦£¬Èç¹ûMysqlʹÓÃÁËgbk×Ö·û¼¯£¬ÔòÒ»¶¨ÒªÉèÖÃ×Ö·û¼¯Îªgbk£¬·ñÔòµ¼Èëµ½Sql Server¿ÉÄÜ»á³öÏÖÎʺÅÂÒÂë¡£
4.´ò¿ªsql serverÆóÒµ¹ÜÀíÆ÷£¬Ð½¨Ò»Êý¾Ý¿âMySql¡£Ñ¡Ôñ¸ÃÊý¾Ý¿â£¬µ¥»÷ÓÒ¼üÑ¡ÔñËùÓÐÈÎÎñ\µ¼ÈëÊý¾Ý¡£
5.Ñ¡ÔñÊý¾ÝԴΪÆäËü(ODBCÊý¾ÝÔ´)£¬Óû§/ϵͳDSNΪmysqlodbc¡£ÆäÓà¸ù¾ÝÏòµ¼½øÐУ¬¼´¿É½«Êý¾Ý´ÓMySqlÊý¾Ý¿âµ¼Èëµ½MSSQLÊý¾Ý¿âÖС£
µ¼Èëµ½sqlserverµÄÊý¾Ý¿â¿ÉÄÜÓÐЩ±íÓдíÎ󣬱ÈÈç±íÖÐÊý¾Ýδµ¼È룬±íÖ÷¼üδÉèÖã¬×ֶθñʽ²»ÕýÈ·µÈµÈ£¬ÒªÖØÐÂÉèÖûò²åÈë¡£
Ïà¹ØÎĵµ£º
½â¾öhibernate+mysql³öÏֵĸôÌìÁ¬½Ó³¬Ê±ÎÊÌâ
³öÏÖ´íÎó£ºSQL Error: 0, SQLState: 08S01
Communications link failure due to underlying exception:
** BEGIN NESTED EXCEPTION **
java.net.SocketException
MESSAGE: Software caused connection abort: socket write error
STACKTRACE:
java.net.SocketExcepti ......
½ñÌìÓöµ½Êý¾Ý¿âµÄÒ»¸öÎÊÌ⣬¾ÍÊÇÿµ±´ÓÖ÷±íÖÐɾ³ýÒ»¸öÖ÷¼üidʱ£¬ÓÉÓÚÓëËûÏà¹ØÁªµÄ±íÖÐÓÐÏà¹ØµÄ×Ö¶ÎÊý¾Ý£¬ËùÒÔÎÞ·¨É¾³ý¡£²éÁËÒ»´ó¶Ñ×ÊÁÏ£¬·¢ÏÖÎÒ½¨±í¹ØÁªÓõÄÊÇon Restrict.¿ÉÄÜÎÊÌâ¾Í³öÔÚÕâÀï°É¡£
Íâ¼üÔ¼Êø¶Ô×Ó±íµÄº¬Òå:
Èç¹ûÔÚ¸¸±íÖÐÕÒ²»µ½ºòÑ¡¼ü,Ôò²»ÔÊÐíÔÚ×Ó±íÉϽøÐÐinsert/update
Íâ¼üÔ¼Êø ......
ÎÒ×°µÄÊÇXpϵͳ£¬µ±ÎÒ×°Sql Server2000Êý¾Ý¿âºó£¬ÓÃJava³ÌÐòÀ´½øÐÐÊý¾Ý¿âÁ¬½Óʱ³ö´íÁË£¬·¢ÏÖÊÇ1433¶Ë¿ÚûÓдò¿ª£¬ÔÚÍøÉÏÕÒÁËЩ½â¾ö°ì·¨£¬·½·¨ËµµÄ²»ÊǺÜÇå³þ£¬»¹ÓеãÂÞàÂÁË¡£ÎÒ½â¾öºó·¢ÏÖ°ì·¨ÊÇ£ºÊ×ÏÈÊDz鿴ÄãµÄ°æ±¾£¬¿ÉÒÔÓÃselect @@versionÀ´²é¿´¡£×°ÍêSql Server 2000 1433¶Ë¿ÚÓÐÊÇûÓдò¿ª£¬¿ÉÒÔÓÃnet -an -p tcp ......
[תÌûÍøÖ·]http://java-2007.javaeye.com/blog/622269
Íü¼ÇMySQL(ºÍPHP´îÅäÖ®×î¼Ñ×éºÏ) ROOTÃÜÂëÊÇÔÚMySQL(ºÍPHP´îÅäÖ®×î¼Ñ×éºÏ)ʹÓÃÖкܳ£¼ûµÄÎÊÌ⣬¿ÉÊÇÓкܶàÅóÓѲ¢²»»áÖØÖÃROOTÃÜÂ룬Äǽпడ£¬ÎÒÓÐÉîÓид¥£¬ÌØд´ËÎÄÕÂÓë´ó¼Ò½»Á÷£º
1¡¢±à¼MySQL(ºÍPHP´îÅäÖ®×î¼Ñ×éºÏ)ÅäÖÃÎļþ£º
windows»·¾³ÖУº%MySQL(ºÍPHP´îÅäÖ ......
Windows:
1. ÓÃϵͳ¹ÜÀíÔ±µÇ½ϵͳ¡£
2. Í£Ö¹MySQLµÄ·þÎñ¡£
3. ½øÈëÃüÁî´°¿Ú(cmd)£¬È»ºó½øÈëMySQLµÄ°²×°Ä¿Â¼£¬±ÈÈçÎҵݲװĿ¼ÊÇc:\mysql,½øÈëC:\mysql\bin
4. Ìø¹ýȨÏÞ¼ì²éÆô¶¯MySQL£¬
c:\mysql\bin>mysqld-nt --skip-grant-tables
5. ÖØдò¿ªÒ»¸öcmd´°¿Ú£¬½øÈëc:\mysql\b ......