数据库操作
Oracle
Dim aDS As OraDynaset
Set aDS = OraDB.DbCreateDynaset(aSql, ORADYN_READONLY + ORADYN_NOCACHE)
Set aDS = OraDB.DbCreateDynaset(aSql, ORADYN_READONLY)
OraDB.ExecuteSQL (aSql)
Set aDS = OraDB.DbCreateDynaset(aSql, ORADYN_READONLY + ORADYN_NOCACHE)
Set aDS = OraDB.DbCreateDynaset(aSql, ORADYN_READONLY)
OraDB.ExecuteSQL (aSql)
参照設定:
Oracle Data Control
Oracle InProc Server 5.0 Type Library
ADO
Dim aRs As ADODB.Recordset
Set aRs = New ADODB.Recordset
aRs.Open aSql, adServerCN, adOpenDynamic
adServerCN.Execute (aSql)
Set aRs = New ADODB.Recordset
aRs.Open aSql, adServerCN, adOpenKeyset, adLockOptimistic
Set aRs = New ADODB.Recordset
aRs.Open aSql, adServerCN, adOpenStatic, adLockReadOnly
Set aRs = New ADODB.Recordset
aRs.Open aSql, adServerCN, adOpenDynamic
adServerCN.Execute (aSql)
Set aRs = New ADODB.Recordset
aRs.Open aSql, adServerCN, adOpenKeyset, adLockOptimistic
Set aRs = New ADODB.Recordset
aRs.Open aSql, adServerCN, adOpenStatic, adLockReadOnly
参照設定:
Microsoft ActiveX Data Object 2.7 Library
DAO
Public WS As Workspace
WS.BeginTrans
WS.CommitTrans
WS.Rollback
Dim aRS As Recordset
Db.Execute aSQL
WS.BeginTrans
WS.CommitTrans
WS.Rollback
Dim aRS As Recordset
Db.Execute aSQL
参照設定:
Microsoft DAO 3.51 Object Library
本作品采用 知识共享署名-非商业性使用 2.5 中国大陆许可协议进行许可。 |