Reports, Forms and Stored Procedures

  • Thread starter Thread starter Bobby Conn
  • Start date Start date
B

Bobby Conn

Hello,

My current situation:

I have a form which generates reports for me. I select the
report I want to create, select the correct parameters and
press go. The form executes the stored procedure and
creates a temporary table from which the report gets its
data.

What I'm aiming for:

I'd like to remove the temporary table from my process. Is
this possible? I've tried numerous things, but I'm unable
to find a way to pass parameters to the report which is
then passed to the stored procedure.

Thanks,
Bobby Conn
 
How does the stored procedure format your data to the temp table? Can it be
done with just queries? These are some of the questions that need to be
answered before your question can be answered. So please post the table
layouts,queries, and stored procedures that are needed to run this report.

HTH
Martin
 
Hi,

Thanks for your quick response.

The only reason I'm currently outputting to a table is was
the quickest way forward for me.

There are around 15 reports, with 15 stored procedures.
Each stored procedure had 4 parameters but I can't seem to
pass the parameters on my form to the report which then
passes them onto the stored procedure.

Currently I'm looking at InputParameters property on my
reports but I can't get that working.

Bobby
 
Managed to fix my problem.

Solution:

The format to pass parameters is:

@paramA varchar=Forms!frmTest!paramA, @paramB
varchar=Forms!frmTest!paramB

Seems simple - but I couldn't find this information
anywhere.

Hope it helps someone else.

Thanks,
Bobby
 
I would just build a pass thru query at runtime that executes the stored
procedure with the right paramaters and
have the report based on the pass-thru query. Example "Exec mystoredproc
@Salary=50000"
 
Back
Top