Creates a new QueryDef object.
Applies to objects: Connection, Database.
[[Set] RetVal = ] object.CreateQueryDef([Name], [SQLQuery]) |
The CreateQueryDef method syntax has these parts:
Part | Description |
object | Required. A reference to an instance of the object. |
RetVal | Optional. A QueryDef type variable. |
Name | Optional. A String type variable. The name of the object being created. |
SQLQuery | Optional. A String type variable. An SQL query. |
The stored procedure will be created in the database after calling the Append method of the QueryDefs collection. It can be performed by the OpenRecordset record, with the name of the QueryDef object as the parameter.
....... |
See Also |
Connection Object, Database Object, QueryDef Object, QueryDefs Object, Name Property, SQL Property, Append Method, OpenRecordset Method. |