Report Design
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Report Design
Message Icon Topic: Complex Prompting Post Reply Post New Topic
Author Message
kkellum
Newbie
Newbie
Avatar

Joined: 15 Feb 2011
Location: United States
Online Status: Offline
Posts: 4
Quote kkellum Replybullet Topic: Complex Prompting
     Posted: 15 Feb 2011 at 12:19pm

Hello everyone,  First let me say I am fairly new to Crystal although I do have a good understanding of most ways of doing things within Crystal.  I have been tasked to create a very complex report where users can enter values for multiple fields over multiple tables.  So here comes the question...

I have 4 tables.  Each table has zero, one or more fields that a user needs to select from and then assign a value, or range of values to each of these.
 
My problem is that the user may need to select the same field more than once and assign a different value to the field.  For instance;
 
I am trying to create a list of patients that are over "18" years old, (from table a), are not = to "white", (from table a) are currently taking the medication "advair", (from table b) or "Xopenex", (from table b) and have lab result for a "CBC" > "120", (table c) and a lab result for Glucose < "170" (table c)
 
My main problem is how do I allow users to be able to select the tables they want to use, then select the fields within those tables they want to use, (possibly more than once) and then assign values to those fields as the criteria for the report.
 
I have tinkered with using dynamic and static parameters but just cannot seem to figure out how to link these together to give me what I need.  There must be a way to do this and ANY help would be GREATLY appreciated.
Just a beginner
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 16 Feb 2011 at 4:05am
Do you really want them to be able to select whatever fields from each table (I think that would be getting into a data cube interface) or do you have pre-defined fields that you want them to be able to choose lists of values from?


Edited by DBlank - 16 Feb 2011 at 4:06am
IP IP Logged
kkellum
Newbie
Newbie
Avatar

Joined: 15 Feb 2011
Location: United States
Online Status: Offline
Posts: 4
Quote kkellum Replybullet Posted: 16 Feb 2011 at 4:29am
I have predefined fields that I want the user to choose from.  The data sets are preloaded before the report runs, I nedd to filter, and sort by multiple combinations for each table.
Thank you for your response! :-)
Just a beginner
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 16 Feb 2011 at 4:31am
are you using 2008 and do you need for users to be able to leave any of the params 'blank'?
IP IP Logged
kkellum
Newbie
Newbie
Avatar

Joined: 15 Feb 2011
Location: United States
Online Status: Offline
Posts: 4
Quote kkellum Replybullet Posted: 16 Feb 2011 at 4:43am
Yes I am using 2008 and yes some parameters need to be left blank.  Thanks again! :-)
Just a beginner
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 16 Feb 2011 at 5:04am
2008 has the option to allow for empty params and I believe that is in the param properties but I have not used it so not sure.
now you have to define your params
 
"18" years old, (from table a), are not = to "white", (from table a) are currently taking the medication "advair", (from table b) or "Xopenex", (from table b) and have lab result for a "CBC" > "120", (table c) and a lab result for Glucose < "170" (table c)
 
 
1 = age - how do you want that to work?
2 = race - do you want this to always be NOT in the selected? Users do not usually get that...
3 = medications - should be easy
4 = lab results - please explain your data and all optiosn you want users to choose from
 
 


Edited by DBlank - 16 Feb 2011 at 5:04am
IP IP Logged
kkellum
Newbie
Newbie
Avatar

Joined: 15 Feb 2011
Location: United States
Online Status: Offline
Posts: 4
Quote kkellum Replybullet Posted: 16 Feb 2011 at 5:55am

Thanks for your prompt responses!

Lets go a different direction here since I can see that this may be in over my head a bit.
 
How can I make an additional prompt appear if a previous prompt is true?  Can this be done?  This may allow me to get to the individual tables that are needed and prompt for the values that I need to filter the report.
 
I hope this makes sense. 
 
Thanks again.
Just a beginner
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 16 Feb 2011 at 6:26am
you can't do thet per se but you can use cascading dynamic params that limit the next selection based on a prior selection.
thsi is defined by your data int he tablse and how they are joined.
never tried it with optional params so not sure how it would respond to that.
the other is not too bad but when you want to do things with age like
 
>18
or
<30
or
between 21 and 24
params are not so good un less you know exaclty all permutations and insert these as elements to choose from. Still very nasty to code.
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