1

Topic: vba ms sql query variables by name

Approximately so I wrote in ,  and other:

select *
from table
where id =:p_id

and  a variable by name that is convenient, since variables in request there can be some tens and everyone can be used some times
Colleagues, prompt, as it is correct for making in + for ms sql

2

Re: vba ms sql query variables by name

andreymx, for example, somehow so:
How to transfer the data from  Excel in sql request?

3

Re: vba ms sql query variables by name

It turns out, only through ?
And requests in any way?

4

Re: vba ms sql query variables by name

andreymx wrote:

it turns out, only through ?
And requests in any way?

It is possible probably, I am simple so did not do never.
At object   sv-in CommandType will be not 4, but 2. Google as requests with parameters - it become.

ADO wrote:

Object Command exists for the job and performance of commands and requests. Though the request can be fulfilled and without usage of object Command (by means of method Execute of object Connection or method Open of object Recordset), object Command is irreplaceable at performance of request with parameters and is convenient in a case when it is required to save the text of a command for its reuse. Object Command can be used both together with object Connection, and without it since the line of connection can be set immediately in property ActiveConnection of object Command.