G
Guest
Hi,
I am using Access as a front end GUI to retrieve data from a database on an
SQL server.
I have created stored procedures that work fine, but now I want to be able
to parameterise them from a form.
I am having great difficulty in getting information on how to reference a
control on a form into a stored procedure.
I have a combo box that will contain the value I wish to pass to the stored
procedure.
The query works fine if I run it by it's self, but cannot seem to get it
going from a form.
Stored Procedure:
ALTER PROCEDURE dbo.StoredProcedure1
(@Assignee varchar(25))
AS SELECT Call, Status, Assignee, LoggedBy, DateRaised, DateCompleted,
Request, Action, SysDateChanged
FROM dbo.SKYSQL02_Envisage_dbo_HD_Call
WHERE (Assignee = @Assignee) AND (NOT (Status IN ('completed',
'Decline/Cancel')))
ORDER BY DateRaised DESC
Also how do I refresh the sub form that I have used to display the data with?
Thanks in advance.
I am using Access as a front end GUI to retrieve data from a database on an
SQL server.
I have created stored procedures that work fine, but now I want to be able
to parameterise them from a form.
I am having great difficulty in getting information on how to reference a
control on a form into a stored procedure.
I have a combo box that will contain the value I wish to pass to the stored
procedure.
The query works fine if I run it by it's self, but cannot seem to get it
going from a form.
Stored Procedure:
ALTER PROCEDURE dbo.StoredProcedure1
(@Assignee varchar(25))
AS SELECT Call, Status, Assignee, LoggedBy, DateRaised, DateCompleted,
Request, Action, SysDateChanged
FROM dbo.SKYSQL02_Envisage_dbo_HD_Call
WHERE (Assignee = @Assignee) AND (NOT (Status IN ('completed',
'Decline/Cancel')))
ORDER BY DateRaised DESC
Also how do I refresh the sub form that I have used to display the data with?
Thanks in advance.