troubleshooting Question

Crystal Report pass multi valued parameter in sub report based on sql command

Avatar of Taras
TarasFlag for Canada asked on
Crystal Reports
14 Comments1 Solution200 ViewsLast Modified:
In my CR 2008 report I have main report as container for two sub reports that are created- based on the same sql command.
I am passing two parameters in each sub report.
 First parameter is ?Run_Date and I am using formula @CustomerNum to pass second parameter ?ListOfCustNum.
In each sub report I created sub report parameter named:
 ?Run_Date and ?CustomerNum – Name is the same as formula in main report.
 In sub report  parameter ?CustomerNum is number type and I did not checked Allow multiple value.
My formula in main report :
@CustomerNum
Numbervar Counter;
Stringvar display;
For counter := 1 to count({?ListOfCustNum}) do (
Display:= display + ToText({?ListOfCustNum}[counter], 0 , ””) +  ”,  “);
Left(display,len(display)-2);

I made links from main to subreport ?Run_Date and @CustomerNum.
I am getting proper date but not passing list of customer numbers in.
In sql command I have in Selection statement something as : Select ….where i.CustomerNum in ({?CustomerNum})
ASKER CERTIFIED SOLUTION
James0628

Our community of experts have been thoroughly vetted for their expertise and industry experience.

Join our community to see this answer!
Unlock 1 Answer and 14 Comments.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 14 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros