The latter approach allows me to send parameters to a saved query via querydefs.
That is a clear and well thought out statement.
Parameter queries are not just limited to the fact that parameters are supplied via form references and parameters then have to be assigned via the parameter list of the query object.
What is best is determined by specific cases.
- The evaluation of a stored procedure returns a recordset, only this one.
- A recordset object already contains the data. If loading and processing backend data is very time-consuming, but functional changes are necessary very often, it will be very valuable to work with the data available in the frontend and therefore not have to reload it every time.
- Sometimes you just already have a recordset object, for whatever reason. Then you can use it immediately:
=> as an argument for a method
=> Excel.CopyFromRecordset
=> Word.ConvertToTable
=> ADODB.Recordset.Getstring
=> disconnected Recordset