常用工具: 简繁转换 HTML/JS互转 Url编码Escape解析 Unicode编码转换 设为首页 加入收藏夹
更多内容
" id="arctext" class="center" " class="arcinfo center" " id="slistl" class="left" " id="mid_slistl_sch" class="left" " id="mid_slistl_adv" class="left" " id="mid_slistl_adv2" " src="http://www.fzs8.net/d/js/acmsd/middle2.js"
文章正文

ASP Hex 函数

来源:  网络收集  字体:[ ]
站内搜索系统
文章正文

ADO Connection连接对象

来源:  网络收集  2007-05-23 05:19:20 字体:[ ]

Connection 对象

The ADO Connection Object is used to create an open connection to a data source. Through this connection, you can access and manipulate a database.
ADO Connection连接对象的作用是:创建一个到数据源的开放式连接。通过这个连接,你可以对数据库进行访问和操作。

If you want to access a database multiple times, you should establish a connection using the Connection object. You can also make a connection to a database by passing a connection string via a Command or Recordset object. However, this type of connection is only good for one specific, single query.
如果你想多次访问数据库,你可以使用Connection对象建立一个连接;你也可以通过一个指令[Command]或记录对象[Recordset]传递一个连接字符串从而来创建一个到数据库的连接。然而,这种连接类型仅适用于明确单一的查询语句

ProgID

set objConnection=Server.CreateObject("ADODB.connection")


Properties
属性

Property属性Description描述
AttributesSets or returns the attributes of a Connection object
设置或返回连接对象的属性
CommandTimeoutSets or returns the number of seconds to wait while attempting to execute a command
设置或返回等待一条指令执行的时间(单位:秒)
ConnectionStringSets or returns the details used to create a connection to a data source
设置或返回用来创建到一个数据源连接的详细设置
ConnectionTimeoutSets or returns the number of seconds to wait for a connection to open
设置或返回等待一个连接打开的时间(单位:秒)
CursorLocationSets or returns the location of the cursor service
设置或返回指针的位置
DefaultDatabaseSets or returns the default database name
设置或返回于指定客户端建立连接的默认数据库的字符串值
IsolationLevelSets or returns the isolation level
设置或返回事件隔离度
ModeSets or returns the provider access permission
设置或返回技术提供对象[provider]的访问权限
ProviderSets or returns the provider name
设置或返回技术提供对象[provider]的名称
StateReturns a value describing if the connection is open or closed
返回一个用于描述连接是否打开或关闭的值
VersionReturns the ADO version number
返回ADO版本号

Methods
方法

Method方法Description描述
BeginTransBegins a new transaction
执行一个新的处理方式
CancelCancels an execution
取消执行一个程序
CloseCloses a connection
关闭一个连接
CommitTransSaves any changes and ends the current transaction
保存所有改变和终止当前处理的信息
ExecuteExecutes a query, statement, procedure or provider specific text
执行一个查询语句、陈述语句、程序或技术提供对象[provider]的详细文本
OpenOpens a connection
打开一个连接
OpenSchemaReturns schema information from the provider about the data source
返回技术提供对象[provider]关于数据源的schema信息
RollbackTransCancels any changes in the current transaction and ends the transaction
取消所有对当前处理的变更和程序的终止

Events
事件

Note:  You cannot handle events using VBScript or JScript (only Visual Basic, Visual C++, and Visual J++ languages can handle events).
注意:你不能通过使用VBScript或JScript来处理这些事件;你只能通过Visual Basic、Visual C++ 和Visual J++来处理这些事件。

Event时间Description描述
BeginTransCompleteTriggered after the BeginTrans operation
BeginTransComplete 在 BeginTrans 操作之后调用
CommitTransCompleteTriggered after the CommitTrans operation
CommitTransComplete 在 CommitTrans 操作之后调用
ConnectCompleteTriggered after a connection starts
ConnectComplete 在 connection 开始之后调用
DisconnectTriggered after a connection ends
Disconnect在 connection结束之后调用
ExecuteCompleteTriggered after a command has finished executing
ExcuteComplete在一个指令结束执行之后调用
InfoMessageTriggered if a warning occurs during a ConnectionEvent operation
如果在执行ConnectionEvent程序时发生错误信息之后调用infoMessage
RollbackTransCompleteTriggered after the RollbackTrans operation
RollbackTransComplete在RollbackTrans操作之后调用
WillConnectTriggered before a connection starts
WillConnect在一个连接开始之前调用
WillExecuteTriggered before a command is executed
WillExecute在一个指令执行之前调用

Collections
集合

Collection集合Description描述
ErrorsContains all the Error objects of the Connection object
包含所有连接对象中的错误对象
PropertiesContains all the Property objects of the Connection object
包含所有连接对象中的属性对象

  
上一篇:ADO Command对象
下一篇:ADO Error对象属性
最新文章
推荐文章
热门文章
版权所有:IT加油站   COPYRIGHT © 2007 WWW.FZS8.NET ALL RIGHTS RESERVED.
闽ICP备08008535号