MYSQL´æ´¢¹ý³ÌVBµ÷Ó÷½·¨¡£
Private Sub Command1_Click()
Dim MyComm As New ADODB.Command '¶¨ÒåÒ»¸öÃüÁî¶ÔÏó
Dim Rs_GetList As New ADODB.Recordset '¶¨ÒåÒ»¸ö¼Ç¼¼¯¶ÔÏó
Dim param As ADODB.Parameter '¶¨ÒåÒ»¸ö²ÎÊý¶ÔÏó
With MyComm
.ActiveConnection = Cn 'Êý¾ÝÁ¬½Ó
.CommandText = "pp" '´æ´¢¹ý³ÌÃû³Æ
.CommandType = adCmdStoredProc '±íÃ÷ÕâÊÇÒ»¸ö´æ´¢¹ý³Ì
.Prepared = True 'ÒªÇó½«SQLÃüÁîÏÈÐбàÒë
Set param = .CreateParameter("@a", adInteger, adParamInput, 4, 3) 'ÉêÃ÷Ò»¸ö²ÎÊý
.Parameters.Append param '°Ñ²ÎÊýÌí¼Óµ½²ÎÊýÁбíÀï
Set Rs_GetList = .Execute 'Ö´Ðд˴洢¹ý³Ì£¬·µ»Ø¼Ç¼¼¯
End With
While Not Rs_GetList.EOF 'Ñ»·´òÓ¡¼Ç¼¼¯µÄ×Ö¶Î
Debug.Print Rs_GetList.Fields(0).Value
Rs_GetList.MoveNext
Wend
End Sub
Ïà¹ØÎĵµ£º
²Ù×÷Êý¾Ý¿â
µÇ¼µ½mysqlÖУ¬È»ºóÔÚmysqlµÄÌáʾ·ûÏÂÔËÐÐÏÂÁÐÃüÁÿ¸öÃüÁîÒԷֺŽáÊø¡£
1¡¢ ÏÔʾÊý¾Ý¿âÁÐ±í¡£
show databases;
ȱʡÓÐÁ½¸öÊý¾Ý¿â£ºmysqlºÍtest¡£ mysql¿â´æ·Å×ÅmysqlµÄϵͳºÍÓû§È¨ÏÞÐÅÏ¢£¬ÎÒÃǸÄÃÜÂëºÍÐÂÔöÓû§£¬Êµ¼ÊÉϾÍÊǶÔÕâ¸ö¿â½øÐвÙ×÷¡£
2¡¢ ÏÔʾ¿âÖе ......
×î½üÓöµ½Ò»¸öÐèÇóÒªÔÚlinuxÏÂÓÃjava µ÷ÓÃmysql¿Í»§¶ËÔ¶³ÌµÇ½mysql·þÎñÆ÷£¬´Ó¿Í»§¶Ë»úÆ÷µ¼Èëmysql½Å±¾£¬´Ómysql·þÎñÆ÷¶Ëµ¼³ö±íÖеÄÊý¾Ý¡£ÒÔÏÂÊÇÓõ½µÄÖ÷Òª·½·¨£º
Java ´úÂë
/**
* µ¼ÈëÊý¾Ý
* @param ½Å±¾µÄµØÖ·ºÍÃû³Æ
* @return ÊÇ·ñ³ ......
10055:ûÓлº´æ¿Õ¼ä¿ÉÀûÓà ·½·¨:²é¿´ÏÂÄãµÄCÅÌ¿Õ¼äÊÇ·ñÒѾÂú,Çå³ýһЩûÓÐÓõÄÎļþ. ¿ÉÒÔÔÚºǫ́µÄ"ÂÛ̳ºËÐÄÉèÖÃ","ºËÐŦÄÜÉèÖÃ"Àï"½ø³ÌÓÅ»¯"¿ªÆô,"GZIP ѹËõÊä³ö"¹Ø±Õ. ²éÕÒÁËÒ»ÏÂ10055£¨Ã»Óлº´æ
˵Ã÷:Èç¹ûÓöµ½Êý¾Ý¿â³ö´íµÄÎÊÌâÐÞ¸ÄÏàÓ¦µÄ´úÂëºóÒ»°ãÒªÖØÆômysql¡£Èç¹ûÓöµ½mysqlµÄÎÊÌâ¿ÉÒÔÏÈÖØÆ ......
Õª³×Ô£ºhttp://database.ctocio.com.cn/153/9232653.shtml
ºÜ¶àʱºò¹ØÐĵÄÊÇÓÅ»¯SELECT ²éѯ£¬ÒòΪËüÃÇÊÇ×î³£ÓõIJéѯ£¬¶øÇÒÈ·¶¨ÔõÑùÓÅ»¯ËüÃDz¢²»×ÜÊÇÖ±½ØÁ˵±¡£Ïà¶ÔÀ´Ëµ£¬½«Êý¾Ý×°ÈëÊý¾Ý¿âÊÇÖ±½ØÁ˵±µÄ¡£È»¶ø£¬Ò²´æÔÚ¿ÉÓÃÀ´¸ÄÉÆÊý¾Ý×°ÔزÙ×÷ЧÂʵIJßÂÔ£¬Æä»ù±¾ÔÀíÈçÏ£º
¡¡¡¡³ÉÅú×°Ôؽϵ¥ÐÐ×°Ôظü¿ì£¬ÒòΪÔÚ×°ÔØÿ¸ö¼Ç ......
ÔÚMySQL 3.23.44°æ±¾ºó£¬InnoDBÒýÇæÀàÐ͵ıíÖ§³ÖÁËÍâ¼üÔ¼Êø¡£
Íâ¼üµÄʹÓÃÌõ¼þ£º
1.Á½¸ö±í±ØÐëÊÇInnoDB±í£¬MyISAM±íÔÝʱ²»Ö§³ÖÍâ¼ü£¨¾Ý˵ÒÔºóµÄ°æ±¾ÓпÉÄÜÖ§³Ö£¬µ«ÖÁÉÙÄ¿Ç°²»Ö§³Ö£©£»
2.Íâ¼üÁбØÐ뽨Á¢ÁËË÷Òý£¬MySQL 4.1.2ÒÔºóµÄ°æ±¾ÔÚ½¨Á¢Íâ¼üʱ»á×Ô¶¯´´½¨Ë÷Òý£¬µ«Èç¹ûÔÚ½ÏÔçµÄ°æ±¾ÔòÐèÒªÏÔʾ½¨Á¢£»
3.Íâ¼ü¹ØÏ ......