using store procedure as recordsource

  • Thread starter Thread starter Roy Goldhammer
  • Start date Start date
R

Roy Goldhammer

Hello there

If i have store procedure with parameters, can i use it as record souce
without the enter parameter value to be opened and the data will be taken
from the current form
 
If i have store procedure with parameters, can i use it as record
souce without the enter parameter value to be opened and the data will
be taken from the current form

Yes, you can.

As form RecordSource property you have to specify something like:

schemaname.spname

then as form InputParameter you have to specify all parameters, in a form
like this:

@parametername parametertype = valueforparameter, .......
 
also, if stored proc is the record source of a subform, and the parameters to the stored procedure are exactly identical to the
names of variables on the main form, then access will automagically pass them to the stored proc for you.
 
Back
Top