domain .tw idv.tw .com.tw
你正在閱覽 :: 繁體中文:: 學習 ASP SQL VB HTML code

學習 .ASP SQL HTML XML CSS JAVA Perl code study
English Chinese_Traditional Chinese_Simplified

你正在閱覽 :: 繁體中文 Chinese_Traditional

學習.主題:
首頁
ASP
. Active-Server-Flash
. Array
. Connection
»CreateObject-SQLserver
. Count
. Counter
. Distinct
. Email
. File
. Folder
. Function
. GetSQLserver
. Header
. mySQL
. Record
. Recordset
. Request
. Response
. Server
. Server-CreateObject
. ServerVariables
. Session
. Special-Symbols
. String
. Sub
. Time
CSS
Ecommerce
HTML
InternetProtocol
JAVA
Microsoft
Robots
SearchEngine
SQL
SQLserver
VBscript
XML

SiteMap

3w....學習.教學 > ASP > connection » createobject-sqlserver

3w learning

connection >
createobject-sqlserver

Title:

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


設 conn 為與主機物件連結
Description:

(conn)ection connection Data Base Provider=SQLOLEDB; ( for SQL Server) Initial Catalog=___ ; ( for SQL Server) attention:: Provider=Microsoft.Jet.OLEDR.4.0; (for Access ) Data Source= .mdb; (for Access )


SQL server 資料庫的連結
需要主機位址
資料庫使用者ID
資料庫使用密碼
資料庫名稱
Example Code:

<% set conn=Server.CreateObject("ADODB.Connection") conn.open "Provider=SQLOLEDB;Data Source=___; User Id=___;Password=___;Initial Catalog=___;" %> <% Dim subSQL, ask1 ask1=request("ask") 'remark: may a submit form subSQL= " order by c1" SQL="select * from aDB where c1='"&ask1&"' "&subSQL Set rs = GetSQLserverStaticRecordset( conn, SQL) %>


Example Result:


Data Source=( server ); .......... maybe IP or URL User Id=___; ......................... User ID Password=___; ...................... Password Initial Catalog=___;" ............... BD name


Data Source=( 主機位置 ); ........ 可為 IP or 網址
User Id=___; ......................... 使用者識別證ID
Password=___; ...................... 密碼Password
Initial Catalog=___;" ............... 資料庫名稱
..
...
...

[ 8/20/2008 ]

www learning school add more scripts and tips memo
You are at >>3WT.EZER.COM >> 3WT.EZER.COM/ASP/CONNECTION/CREATEOBJECT-SQLSERVER.ASP>>ASP
Helpful link:: SEO web tools :: Live PR | SERP checker
back to top Ezer code adding :: Questions ;email