Link to home
Start Free TrialLog in
Avatar of vbjohn
vbjohn

asked on

Suppress every 2nd and 3rd record

I need to suppress every 2nd and 3rd record that comes through.  I am using Crystal Reports 9.  I need to add this in the Formula Editor.

Any examples?
Avatar of dsacker
dsacker
Flag of United States of America image

Crystal Report does not evaluate the reserved variable "RecordNumber" at record selection time, but you could put this in your detail section for the "Suppress" option.

Just right-click on the detail section, go into Section Expert, select the X-2 for the Suppress, and enter the following formula:

    Remainder (RecordNumber, 3) <> 0

That will suppress the 2nd and 3rd records.
Avatar of vbjohn
vbjohn

ASKER

No that does not work.
Avatar of vbjohn

ASKER

Record 1
109039 - L9090 - DCR001
Record 2
109039 - L9090 - 999999
Record 3
109039 - L9090 -888888
Record 4
109040 - L9777 - YW1004
Record 5
109040 - L9777 -9912323
Record 6
109040 - L9777 -8888888

I need to see....
Record 1
109039 - L9090 - DCR001
Record 4
109040 - L9777 - YW1004
ASKER CERTIFIED SOLUTION
Avatar of dsacker
dsacker
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Put the Record Number in your report temporarily, and you'll see which number record is being allowed.
If that doesn't work try

(RecordNumber MOD 3) <> 1

mlmcc
Avatar of vbjohn

ASKER

You are awesome!   Thanks.
Glad I could help.