ADO Constants
Tobi
- asp.net
0 bernd
Hallo,
ich bin bei mehreren ASP Tutorials ueber ADO Constants gestolpert, ohne dass ihre Funktion naeher erlaeutert wurde...
Kann mir jemand erklaeren, wofuer z.B. die Konstante
Const adCmdTableDirect = &H0200
gesetzt wird beim Oeffnen des recordsets?
Danke & Gruss
Tobi
Hallo,
Direct Table Access
By default, recordsets are based on SQL statements that retrieve rows from the specified data source. Even if you specify the name of a table as the Source parameter to the recordset's Open method, ADO will translate this into the SQL statement
SELECT * FROM Source
and send that statement to the OLE DB provider to be evaluated.
Using SQL statements to retrieve records allows ADO to work with the most general OLE DB providers. However, with some providers (including the Jet and SQL Server OLE DB providers), you can bypass building a SQL statement when your data source is an actual table in the database. To do this, you specify adCmdTableDirect as the Options parameter to the Open method of the recordset.
If you want your code to be as general as possible for use against any OLE DB provider, you should avoid the adCmdTableDirect option. However, some operations (such as using the Seek method to locate a record using an index) can only be performed if you use adCmdTableDirect.
<
Also keine Statement-Überprüfung durch den entspr. OLE DB Provider und dadurch etwas schneller aber auch etwas unsicher, weil ohne OLE DB Provider, und der kennt das angesprochene DBMS besser und weiß ob es da Schwachstellen gibt.
bernd