Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > .NET > Other .NET > Crystal Reports
Password Reminder
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
Crystal Reports General discussion about Crystal Reports. For discussions specific to the book Professional Crystal Reports for VS.NET, please see the book discussion forum for that book.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Crystal Reports section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old May 21st, 2007, 03:49 AM
Registered User
Join Date: May 2007
Location: , , .
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default Passing Paramter-Stored Procedure

I have one main report and few subreports..All the Subreports take 2 parameters which are passed through (Have used subreport links) ..The parameters are getting passed correctly where my subreports use command/query from the Universe ..But One of my Subreport is using Stored Procedure having same number of paramters. But When I run the whole report ..I am again prompted for the stored procedure parameter... What I am doing wrong here? I am not able to achieve What I want to achieve :( Passing parameters from Main report(running it through Info view) and make it accessible to all of the subreports...Please advise. Thanks
Reply With Quote
  #2 (permalink)  
Old May 22nd, 2007, 11:21 AM
Registered User
Join Date: May 2007
Location: , , .
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts

I have the same issue. My main report uses a simple table, however, the subreport uses a stored proc. If I use a table instead of a stored proc, I can link the parameters up just fine and I'm not prompted multiple times for the same parameter.

Crystal XI.

Reply With Quote
  #3 (permalink)  
Old May 22nd, 2007, 11:34 AM
Registered User
Join Date: May 2007
Location: , , .
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts

Oops, I had to change my Parameter in the stored proc to match that of the original parameter's type (string = varchar).

Primary report parameter = CustID (string).
Stored Proc now has CustID (varchar).

Verified my subreport to pick up the change.
On main report, right click subreport and choose Change Subreport Links.
In available fields, select the formula field you made that reflects the value of your primary report parameter (CustID).
In the 'Subreport Parameter field to use' select the parameter from your subreport. (?@CustID, NOT ?Pm-CustID!).

That should do it. At least it did for me. Hope that works!

Reply With Quote

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Passing Array to Oracle Stored Procedure kulkarnimonica Oracle ASP 1 August 6th, 2007 02:22 AM
Passing an "IN" clause to a stored procedure atcs2152 SQL Server 2000 5 February 7th, 2006 10:55 PM
Passing datasource to a stored procedure ctranjith SQL Server 2000 2 October 7th, 2004 01:49 PM
Passing a parameter value to Stored Procedure mcinar SQL Server 2000 9 October 3rd, 2004 09:42 PM
passing stored procedure shoakat SQL Server 2000 1 July 15th, 2004 09:20 AM

All times are GMT -4. The time now is 02:31 PM.

Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.