Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

count only records shown

Status
Not open for further replies.

stussy

MIS
May 22, 2003
269
GB
Hi

I'm sure this is easy, but is it possible to have a count field which only counts records you are showing? I have a suppression on some records, but they are still included in a count - how do I stop this?

Cheers
 
You can use a running total field to do this.

Go to insert/field object create a running total. Set the type of summary to Count. For the "evaluate" part, choose Formula and then use the reverse logic that you are using to suppress. For example, if you are using:
{field} = &quot;Hide&quot; to suppress, use {field}<>&quot;Hide&quot; to



Mike
 
Cheers for the reply Mike. I can see your logic here 100%, and was convinced that it would work...but it doesn't seem to.

Have added running total > count field, have created formula like this:

{ClubMember.email} <> &quot;x@y.co.uk&quot;
or {ClubMember.email} <> &quot;z@n.com&quot;
or {ClubMember.email} <> &quot;g@.co.uk&quot;
or {ClubMember.email} <> &quot;n@l.co.uk&quot;

but it still gives me the total number of recs. Is there something else I may be missing?

Cheers

Another Mike
 
Here is your formula in an easier form (at leat for me) It is basically asking to evaluate if the ClubMember.email is are not one of...

not({ClubMember.email} in [&quot;x@y.co.uk&quot;, &quot;z@n.com&quot;, &quot;g@.co.uk&quot;,&quot;n@l.co.uk&quot;])

or for you suppression - suppress is email is one of these
{ClubMember.email} in [&quot;x@y.co.uk&quot;, &quot;z@n.com&quot;, &quot;g@.co.uk&quot;,&quot;n@l.co.uk&quot;]





Mike
 
Mike - I've fixed it cheers - just added them as a select expert rather than details suppression and all is well - cheers for your help anyway!
 
lol yup that's what my select expert is!

Nice one bruvva!
 
Glad your figured it out.

I forgot brackets. Should have been
not({ClubMember.email} in [&quot;x@y.co.uk&quot;, &quot;z@n.com&quot;, &quot;g@.co.uk&quot;,&quot;n@l.co.uk&quot;])


Mike
 
Wake up, Mike!

That's still not it ... but we get what you mean. [wink]
 
heh I thought 'why has someone replied to this again'?

the answer is in the ) yeah?

he pointed me in the right direction anyway. I might just hand some stars out indiscriminately :)
 
No, the ()'s are cool. It's that the multiple emails need to be encased in []'s, as they constitute an array. So the whole thing looks like: not({X} in [x,y,z]).

But as you've opted to lose the records you don't need at the record selection stage - which is the best option - this is a moot point.

All the best with your report.

Naith
 
I could swear I put them in. I bet if it's the TGML.

I just did the Preview Post, and they dissappeared.

That's never happened before with the TGML turned on. As far as I can remember.

It looks like if I put &quot;'s inside the []'s the []'s dissappear.
Code:
[&quot;&quot;] []
resulted as:
&quot;&quot; []


Mike
 
Wrap any code inside [ignore]
Code:
[/ignore] and you don't have to worry about losing the brackets.

~Brian
 
It IS the TGML, and I regularly uncheck it when using brackets in a post(or if using as a subscript, to avoid the interpretation as italics) because of this problem.

-LB
 
I knew about using [ignore]
Code:
[/ignore], but didn't realize the &quot;&quot;'s inside the brackets would elimiante them.


Mike
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top