Visual Basic Concepts

Using SQL PassThrough Queries with DAO

In many applications, you’ll use both Jet queries (that is, queries executed by the Jet database engine) based on attached remote tables and SQL pass-through queries. With a Jet query, the query engine determines which parts of the query can be sent to the server and which parts must be processed locally, thereby combining the power of the server with the capabilities of the Jet database engine. With a DAO Jet SQL pass-through query, your code provides a SQL statement that Jet sends directly to the server without stopping to compile the query. Once the SQL pass-through query is complete, if it creates a result set, the Jet recordset processor creates a snapshot-type Recordset object to manage it.