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

Á¬½Ó´øÃÜÂëµÄACCESSÊý¾Ý¿âд·¨

dim conn
dim connstr
dim db
dim dbpaswd  (Õâ¸öÃÜÂë¼ÓÔÚÄÄ)
db=dbpath&"/"&dbname
connstr="DBQ="+server.mappath(""&db&"")+";DefaultDir=;DRIVER={Microsoft Access Driver (*.mdb)};"


set conn=server.createobject("ADODB.CONNECTION")
on error resume next
conn.open connstr
if err then
Err.Clear
Call CloseConn()
Response.Write "Êý¾Ý¿âÁ¬½Ó³ö´í£¬Çë¼ì²éÊý¾Ý¿âĿ¼ºÍÊý¾Ý¿âÎļþÃûÊÇ·ñÕýÈ·¡£"
Response.End
end if
connstr = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\mydatabase.mdb;User Id=admin;Password=xxx;"

Õâ¸öд·¨ÎÒ»¹ÓÃÄã½²Â𠣿

ÒýÓÃ
Õâ¸öд·¨ÎÒ»¹ÓÃÄã½²Â𠣿

ÕâôţX£¬ÄÇÄ㻹ÊÇ×Ô¼ºÂýÂý¸ã°É£¡

VBScript code:

Access 97/2000/XP/2003 Database Connection String using Microsoft Access Driver (DSN less)

<%@LANGUAGE=VBSCRIPT%>
<%
Option Explicit
Dim strConnection, conn, rs, strSQL

strConnection = "Driver={Microsoft Access Driver (*.mdb)};" & _
"Dbq=" & Server.MapPath(".\db\db.mdb") & ";Uid=admin;Pwd=password;"

Set conn = Server.CreateObject("ADODB.Connection")
conn.Open strConnection

Set


Ïà¹ØÎÊ´ð£º

Access Êý¾ÝÉýǨµ½ SQLServer2005

ÎÒÔ­±¾ÊÇÓÃACCESSµÄÊý¾Ý¿â£¬ÏÖÔÚ¸ÄÓÃSQLServer2005ÁË£¬ËùÒÔÏë°Ñ֮ǰµÄÊý¾ÝÈ«¶¼µ¼µ½SQLSERVERÀïÀ´¡£
ÏÖÓÐÎÊÌâÈçÏ£º

1:¸ÄÓÃSQLserverºó£¬Êý¾Ý¿âµÄ½á¹¹Óи͝¡£Ô­±¾ÔÚaccessÖÐËùÓеĵ¥¾ÝÓÃÒ»¸ö¡°µ¥¾ÝÐÅÏ¢¡±Ö ......

accessÖÐlikeд·¨

sqlÓï¾äÊÇÕâÑùдµÃ 
string sql = "select * from shophistory where username(stringÀàÐÍ)¡¡like '%"+ name +"%' ";
½á¹ûÔËÐб¨´í£º(²Ù×÷·û¶ªÊ§) ÔÚ²éѯ±í´ïʽ  ˵ºó ......

access µ¼Èë access ת»»ÎÞЧ!ÔÚÏßµÈ!

´ÓÀàÐÍ"DBNULL" µ½ÀàÐÍ¡°Double¡±µÄת»»ÎÞЧ£¨Êý¾Ý¿âÖжÔÓ¦µÄ a3 »òa5 ûÓÐÊý¾ÝÊÇΪ¿Õ£©
,ÇëÎÊÎÒÔõô´¦Àí£¡

VB.NET code:

Dim a1 As String = Nothing
Dim a2 As S ......

ACCESS½¨±íÎÊÌâ

m_pConnect->BeginTrans();
strSql.Format("CREATE TABLE SysUser(lsh AUTOINCREMENT NOT NULL UNIQUE,PRIMARY KEY(lsh),userType BYTE)");
m_pConnect->Execute((_bstr_t)strSql,NULL, adExe ......

access ²éѯ¼Ç¼µÄÎÊÌâ?

ÎÊÌâÈçÏ£º

ÓòéѯÓï¾ä
select * from tab where fil like 'CK090902'ÄܲéÕÒ³öÒ»Ìõ¼Ç¼²¢ÏÔʾ³öÀ´
¸ÄΪ
select * from tab where fil = 'CK090902'
¾Í²»ÄܲéÕÒµ½£¬Ò²ÏÔʾ²»³öÀ´ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ