Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: i think its a formula question (noob) Post Reply Post New Topic
Author Message
shallowz
Newbie
Newbie


Joined: 06 Jan 2012
Location: United States
Online Status: Offline
Posts: 5
Quote shallowz Replybullet Topic: i think its a formula question (noob)
     Posted: 06 Jan 2012 at 4:31am

I am a beginner crystal designer the company is not willing to train me on the software so poking my way through

 

How best should I do this?

 

The company I work for is requesting a report on people who do not have online accounts

 

Each person in the database has an account number section and a section that displays www if they have an online account. There are other info in the same section as the www like “vru” “dbtb” and others. Every time www, vru, or dbtb show as an individual data

 

Meaning:

Account #     User name     Agree Type

000232         Joe Smo          vru
000232         Joe Smo          dbtb
000232         Joe Smo          www
000888         sue wall          vru
000888         sue wall          dbtb
000512         Jeff John          vru
000512         Jeff John          vru
000512         Jeff John          www

 

What I want the report to display is only the accounts that do not have www like “sue wall” the other two accounts have www so I do not want to see them.

 

The result would only display:

 

000888         sue wall          vru
000888         sue wall          dbtb

 

My thinking of how to do a without report would be

 

If www shows up then do not display any information from that account number

 

But how do I do that. Thank you for any help



Edited by shallowz - 06 Jan 2012 at 4:32am
IP IP Logged
rkrowland
Senior Member
Senior Member
Avatar

Joined: 20 Dec 2011
Location: England
Online Status: Offline
Posts: 259
Quote rkrowland Replybullet Posted: 06 Jan 2012 at 5:22am

Group by UserName - add a summary field which counts www for each group.

Goto Report > Selection Formulas > Group...
 
and set it to only return groups where the count summary field = 0.
 
 
IP IP Logged
lockwelle
Moderator
Moderator


Joined: 21 Dec 2007
Online Status: Offline
Posts: 4374
Quote lockwelle Replybullet Posted: 06 Jan 2012 at 8:18am
I've never done what rkrowland suggests, and if it works that is probably more elegant than mine solution:
1 group by username
2 suppress the group header and details
3 create a formula for the header section like:
        shared booleanvar found := false;
4 create a formula for the detail section like:
       shared booleanvar found;
   if {table.agree} = "www" then found:=true;
 
5 in section expert for the group footer/suppression/x-2
      shared booleanvar found;
       found
 
what this does is 3) resets the flag for each group
  4) set the flag if the user has www
  5) conditionally suppresses the group footer if they have www
 
probably the biggest reason that I have never done as ekrowland suggests is that when I was taught...by a seagate tech support person (that's how long ago it was) he said not to use the group option in the selection formulas...so I never have.
 
again if ekrowland's suggestions works, it looks simpler to implement than my suggestion.
 
HTH
 
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