Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: Avoiding Missing Data Post Reply Post New Topic
Author Message
bobbabuoy
Newbie
Newbie


Joined: 10 Mar 2008
Location: United States
Online Status: Offline
Posts: 37
Quote bobbabuoy Replybullet Topic: Avoiding Missing Data
    Posted: 02 Apr 2008 at 4:41pm
I have a report that involves several tables via joins.  I want to NOT show records where data is missing (is: IsNull) in these fields.  Here is what I have tried in the "Edit Selection Formula" to no avail:


not(IsNull({Orders.Accessory Style #}) and IsNull({Orders.Pants Style #}) and IsNull({Orders.Shirt Style #}) and IsNull({Orders.Coat Style #}))


Thanks...
IP IP Logged
Iago
Groupie
Groupie
Avatar

Joined: 01 Oct 2007
Location: United States
Online Status: Offline
Posts: 52
Quote Iago Replybullet Posted: 04 Apr 2008 at 2:26pm
With the "and" all need to be null, try using "or"
IP IP Logged
bobbabuoy
Newbie
Newbie


Joined: 10 Mar 2008
Location: United States
Online Status: Offline
Posts: 37
Quote bobbabuoy Replybullet Posted: 07 Apr 2008 at 4:40am
I want them to all be null to hide this record.  If any one of them is not null then I want the record to show.
IP IP Logged
Iago
Groupie
Groupie
Avatar

Joined: 01 Oct 2007
Location: United States
Online Status: Offline
Posts: 52
Quote Iago Replybullet Posted: 07 Apr 2008 at 8:18am
In the section expert, it is possible to supress any section including the detail section based on a formula that returns a boolean.
 
CLick on the x+2 button next to the suppress checkbox.
 
This button will turn red when there is a formula behind it.
 
The formula overides the check box, so unchecking the checkbox will not keep the formula from suppressing records.
 
It should also be possible to use the Show formula option in the select expert.  That will not hide the records, but instead never return the records to Crystal.
IP IP Logged
JohnT
Groupie
Groupie
Avatar

Joined: 20 Jan 2008
Online Status: Offline
Posts: 92
Quote JohnT Replybullet Posted: 16 Apr 2008 at 1:21pm
Wouldn't you just take the 'NOT' off the formula ?  If they are all NULL, you get true and the line is suppressed.
IP IP Logged
JohnT
Groupie
Groupie
Avatar

Joined: 20 Jan 2008
Online Status: Offline
Posts: 92
Quote JohnT Replybullet Posted: 16 Apr 2008 at 1:25pm
Sorry I forgot something.  Take the NOT off and put the formula in the suppress detail line in the section expert.  That way, if the formula is true, the line is suppressed.
IP IP Logged
bobbabuoy
Newbie
Newbie


Joined: 10 Mar 2008
Location: United States
Online Status: Offline
Posts: 37
Quote bobbabuoy Replybullet Posted: 16 Apr 2008 at 2:41pm
Turns out that the fields were "not null" but they were showing no data.  I took the "not" out and replaced the formula with:

{Orders.Accessory Style #} & "" = "" and {Orders.Pants Style #} & "" = "" and {Orders.Shirt Style #} & "" = "" and {Orders.Coat Style #} & "" = ""

and it worked just fine.

BTW, is there a better way to do that?

Thanks for your help, all!
IP IP Logged
Post Reply Post New Topic
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



This page was generated in 0.031 seconds.