Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: Cascading Dynamic Params Printing "ALL" Post Reply Post New Topic
Author Message
richtreff
Newbie
Newbie


Joined: 21 Feb 2008
Location: United States
Online Status: Offline
Posts: 3
Quote richtreff Replybullet Topic: Cascading Dynamic Params Printing "ALL"
     Posted: 21 Feb 2008 at 5:47am
When using Static Params, you can set up "ALL" as an optional value to bypass filters and can print same in the report header.
 
In XI, how can you print "ALL" when the user selects all the Dynamic Values rather than printing each individual value?
 
Confused
RichT
IP IP Logged
BrianBischof
Admin Group
Admin Group
Avatar

Joined: 09 Nov 2006
Online Status: Offline
Posts: 2458
Quote BrianBischof Replybullet Posted: 21 Feb 2008 at 6:01pm
I show you how to fix this problem in Chapter 4 of my book Crystal Reports Encyclopedia.

What you need to do is modify the SQL query that is the data source for you DCP. In your select statement, include an 'All' constant. This way it can be displayed in the DCP list of values.
SELECT 'ALL', Country, City FROM tblLocation

Please support the forum! Tell others by linking to it on your blog or website:<a href="http://www.crystalreportsbook.com/forum/">Crystal Reports Forum</a>
IP IP Logged
richtreff
Newbie
Newbie


Joined: 21 Feb 2008
Location: United States
Online Status: Offline
Posts: 3
Quote richtreff Replybullet Posted: 23 Feb 2008 at 6:05pm
Brian:
 
Thanks for the feedback, but I really do not know what to click on to "modify the SQL query" you refer to.
 
Thanks again!
RichT
IP IP Logged
BrianBischof
Admin Group
Admin Group
Avatar

Joined: 09 Nov 2006
Online Status: Offline
Posts: 2458
Quote BrianBischof Replybullet Posted: 23 Feb 2008 at 6:40pm
Hmmm... that concerns me that you aren't that familiar with using SQL in a report. Doing this will require knowing how to write an SQL statement.

To do this you need to use a SQL Command as your data source for the DCP. By using a SQL Command you can enter a custom SQL query for retrieving the specific data you want. In the Sql Command is where you would add the "ALL" option to the SELECT statement. If you are using a stored procedure in SQL as the data source, then you would have to modify the stored procedure to return the "ALL" value as a field.
Please support the forum! Tell others by linking to it on your blog or website:<a href="http://www.crystalreportsbook.com/forum/">Crystal Reports Forum</a>
IP IP Logged
richtreff
Newbie
Newbie


Joined: 21 Feb 2008
Location: United States
Online Status: Offline
Posts: 3
Quote richtreff Replybullet Posted: 27 Feb 2008 at 10:30am
Brian:
 
Thanks for your patience.
 
Status:
 
I created a test query to use as a start of the source for my DCP (rather than the fields available from the Oracle views) using the format from the SQL expression editor (Select 'ALL', "APPL"."NAME" from "ISM"."APPLICATION" "APPL"). This executes under Oracle, but Crystal is giving text error message.
 
I also pasted in the Crystal generated Query from the Show Query output, and got the same syntax error.
RichT
IP IP Logged
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum