aspÍøÕ¾´ÓACCESSתSQLSERVER
Ç°¼¸ÌìΪÖÆ×÷Ò»¸öÍøÕ¾£¬ÐèÒª´ÓACCESSתÖÁSQLSERVER£¬´ÓÍøÕ¾Éϲ鿴Á˺ܶàµÄ×ÊÁÏ£¬µ«¾õµÃûÓÐÒ»¸öÄܹ»È«Ã渲¸ÇÒªµãµÄ£¬ËùÒÔÎÒ×ܽáһϣ¬Ë³±ã
¸ø³öһЩ¾Ñé¡£
Ê×ÏÈÈç¹ûÒ»¿ªÊ¼¾ÍÐèÒªÖÆ×÷SQLSERVERµÄÍøÕ¾£¬ÄÇô×îºÃ½«ÄãµÄ°®»ú×°ÉÏWINDOWS2000»òÕß2003ÕâÑùµÄSERVER°æ£¬ÕâÑùµÄ°æ±¾ÊÇÖ§³Ö
SQLSERVERÕýʽ°æµÄ°²×°µÄ£¬¶øXPÖ»ÄÜÖ§³Ö¸öÈË°æ»òÕß¿ª·¢°æ£¬ÎÒûÓÐ×°¹ý£¬µ«¶ÔÓÚµ÷ÊÔÍøÕ¾¶øÑÔ×îºÃ»¹ÊÇÔÚÕýʽ°æϹ¤×÷£¬×ª»¯µÄÕû¸ö¹ý³Ì²»ËãÌ«¸´
ÔÓ£¬µ«ÖÁÉÙ¿ÉÒÔÊ¡ÏÂһЩ¾«Á¦¡£Îҵİ®»úÊÇXP£¬ËùÒÔÖ»ºÃÏÈÓÃACCESSµ÷ÊÔ¡£
ºÃÁË£¬µ±ÄãÕÒµ½Ò»Ì¨×°ÓÐSQLSERVERµÄ»úÆ÷ʱ£¬Äã±ã¿ÉÒÔ¿ªÊ¼×ª»»²¢µ÷ÊÔÁË¡£
1¡£ÏÈÀûÓÃת»¯Èí¼þ£ºCooSel2.0 CreateSQL
V1.05£¬ÎÒÓõÄÕâ¸ö£¬·Ç³£ºÃÓ᣾ßÌå²Ù×÷µÄ»°£¬ÎÒÓõÄÊÇÉú³ÉÉýǨSQL½Å±¾£¬±£´æΪ
*.sqlÎļþºó£¬ÔÚSQL2000µÄ²éѯ·ÖÎöÆ÷Àïµ÷ÈëÖ´ÐС£¶øSQLSERVERµÄ¾ßÌå²Ù×÷Ôڴ˲»±ã׸Êö¡£ÕâÑù£¬ÄãµÄÊý¾Ý¿â¾Íת»¯³ÉÁËMSSQLÊý¾Ý¿â
2¡£¶Ôasp¶øÑÔ£¬Ê×ÏÈÊÇÊý¾Ý¿âÁ¬½ÓÎļþµÄÐ޸ģºÕâµã¿ÉÒԲο¼¶¯ÍøÂÛ̳µÄconn.asp
Dim ConnStr
'sqlÊý¾Ý¿âÁ¬½Ó²ÎÊý£ºÊý¾Ý¿âÃû¡¢Óû§ÃÜÂë¡¢Óû§Ãû¡¢Á¬½ÓÃû£¨±¾µØÓÃlocal£¬ÍâµØÓÃIP£©
Dim
SqlDatabaseName,SqlPassword,SqlUsername,SqlLocalName
SqlDatabaseName =
"dvbbs7" 'Êý¾Ý¿âÃû³Æ
SqlPassword = "" 'Êý¾Ý¿âÃÜÂë
SqlUsername =
"dvbbs" 'Êý¾Ý¿âÓû§Ãû
SqlLocalName = "(local)"
ConnStr =
"Provider = Sqloledb; User ID = " & SqlUsername & "; Password = "
& SqlPassword & "; Initial Catalog = " & SqlDatabaseName
& "; Data Source = " & SqlLocalName & ";"
On Error Resume
Next
Set conn = Server.CreateObject("ADODB.Connection")
conn.open
ConnStr
¼´Ö»ÐèÒªÐÞ¸ÄÊý¾Ý¿âÃû³Æ¡¢Óû§ÃûºÍÃÜÂë¼´¿É¸²¸ÇÔÀ´µÄACCESSÁ¬½Ó·½·¨²¢Ê¹Óá£Èç¹ûÄãµÄÍøվͬʱ°üº¬Á˶¯ÍøÂÛ̳£¬Ôò¿É¸ù¾Ý1¡£µÄ²Ù×÷½«¶¯ÍøµÄÊý
¾Ý¿âҲת»»³ÉSQLSERVER£¬ÖµµÃ³ÆµÀµÄÊÇ£º¶¯Íø¿¼ÂÇÁËACCESSºÍSQLSERVERÁ½ÖÖÊý¾Ý¿âµÄʹÓã¬Òò´ËÔÚÐÞ¸ÄASPÔ´´úÂëµÄʱºò²»ÐèÒª¶Ô¶¯
ÍøµÄÔ´´
Ïà¹ØÎĵµ£º
1.Èç¹ûÄúµÄ²Ù×÷ϵͳΪWindows 98£¬ÇëÔËÐÐ Windows98µÄ°²×°¹âÅÌ¡£ÔÚÆäAdd-ons\pwsĿ¼ÏÂÕÒµ½pwsµÄ°²×°³ÌÐò£¬ÔËÐа²×°¼´¿É
2.Èç¹û²Ù×÷ϵͳΪ Windows 2000 ÒÔÉÏ£¬¿ÉÒÔ°´Í¼4.1.1µÄ·½·¨°²×° IIS£º
´ò¿ª¡¾¿ØÖÆÃæ°å¡¿£¬ÕÒµ½ ¡¾Ìí¼Ó/ɾ³ý³ÌÐò¡¿→¡¾Ìí¼Ó/ɾ³ýWINDOWS×é¼þ¡¿£¬
µ¯³ö ¡¾Windows ×é¼þÏòµ¼¡¿ £¬Ñ¡Ôñ ¡¾Internet ......
<?php
$connstr="DRIVER={Microsoft Access Driver (*.mdb)}; DBQ=" . realpath("data.mdb");
$connid=odbc_connect($connstr,"","",SQL_CUR_USE_ODBC);
$issuetime=date("Y-m-d H:i:s");
$sql="insert into test values("","",...)";
$result=odbc_exec($connid,$sql);
if($result) echo "successful";
else ec ......
1¡£Éî²ã´ÎÀ´ËµÕâ²»ÊÇasp.net µÄÎÊÌ⣬¶øÊÇhtml form µÄsubmit °´Å¥¾ÍÊÇÈçºÎÉè¼Æ¡£
µ±ÄãµÄ¹â±ê½¹µã½øÈëij¸ö±íµ¥ÔªËصÄʱºò£¬»á¼¤»î¸Ã±íµ¥µÄµÚÒ»¸ö£¨
Á÷²¼¾Ö˳´Ó×óµ½ÓÒ£¬´ÓÉÏÖÁÏ£©
type=submit µÄ°´Å¥£¨¼ÙÈçÓУ©£¬µÈ´ýÏìÓ¦»Ø³µÊ¼þ£¬²¢Ìá½»¸Ãform
Äã¿ÉÒÔ²âÊÔһϴúÂë
<form action="">
<input type ="t ......
asp ÖÐÎÄÂÒÂë,asp access ÂÒÂë,asp ˢкóÂÒÂë,asp utf 8ÂÒÂë,ajax ÂÒÂë asp,asp ºº×ÖÂÒÂë,aspÂÒÂëÔõô°ì
ÓÃutf-8±àÂëÓÃÔÚеÄÍøÕ¾ÉÏ£¬²»ÏëÎÊÌ⻹Õæ¶à£¬ËùÒÔÕÒÁËЩÎÄÕ£¬Ìû×Ó£¬¿´ÁË¿´£¬µÈÏÂÓÐÓõľÍÌùÏÂÃæÁË¡£
½ñÌ죬ÎÒ¿ªÊ¼°Ñ CODEPAGE="936" ¸Ä³É CODEPAGE="65001"
°Ñcharset=gb2312¸Ä³É charset=utf-8
¿ÉÊÇ»¹ÊÇÂÒÂë ......