Currently i am working in a project of report generation in MS ACCESS.
The tables are in sql server 2000.
I have to write stored proc in ms access.
Illustration:
I am having a stored proc as follows
name: myproc
-------------------
Create procedure my_proc
@f1 char(1),
@f2 char(5)
As
select * from table1 where field1=@f1 and field2=@f2
_______________ _______________ _______________ ___
and calling proc
name: call_myproc
execute my_proc 'A','2004'
It works fine. I have got all the values which satisfies the above condition in report.
If i am getting the vales of field1 and field2 from forms (form_a) in ms access.
I have to write the calling proc as follows
my_proc [forms]![form_a].[Combo4],[forms]![form_a].[text12]
But ms access throws syntax error.
How is it possible to pass values from ms access FORMS to a calling stored procedure.
could you please help me to fix this problem ?
The tables are in sql server 2000.
I have to write stored proc in ms access.
Illustration:
I am having a stored proc as follows
name: myproc
-------------------
Create procedure my_proc
@f1 char(1),
@f2 char(5)
As
select * from table1 where field1=@f1 and field2=@f2
_______________ _______________ _______________ ___
and calling proc
name: call_myproc
execute my_proc 'A','2004'
It works fine. I have got all the values which satisfies the above condition in report.
If i am getting the vales of field1 and field2 from forms (form_a) in ms access.
I have to write the calling proc as follows
my_proc [forms]![form_a].[Combo4],[forms]![form_a].[text12]
But ms access throws syntax error.
How is it possible to pass values from ms access FORMS to a calling stored procedure.
could you please help me to fix this problem ?
Comment