cancel
Showing results for 
Search instead for 
Did you mean: 

How to suppress row if record similar to previous

Former Member
0 Kudos

Hi,

I have searched this forum and various others but I am unable to find the solution I need for my issue.

I have a report that consist of just one report field 'USERID', which is placed within the details section.

This field contains records that are not necessarily duplicated but are related to the previous record. For instance...

USERID

AADMIN

AADUMMY

AAPPLE

AAPPLE1

AAPPLE2

AAPPLE3

AATKIN

AAUSTIN

....

....

....

In this particular scenario I would like like to suppress 'AAPPLE1', 'AAPPLE2', & 'AAPPLE3'.

I would appreciate any assistance with this.

Kind regards

Gary

Accepted Solutions (1)

Accepted Solutions (1)

abhilash_kumar
Active Contributor
0 Kudos

Hi Gary,

If two or more rows are related to each other, would the second (or subsequent rows) be suffixed with an incrementing number?

-Abhilash

Former Member
0 Kudos

Yes they would indeed. However sometimes there may be unique ID's that are suffixed with a number...

ABEAGER

ABEAN

ABEAN2

ABEAU

ABECKET1

ABER

The only USERID that needs to be suppressed here is 'ABEAN2'.

Thanks

abhilash_kumar
Active Contributor
0 Kudos

OK. Try this please:

1) Create a formula with this code"

stringvar s := {UserID};

Replace(s, totext(val(StrReverse(s)),0,""),"");


2) Go to the Group Expert > Move the formula field from Step 1 to the Pane on the right so that a Group is inserted on this formula field


3) Instead of placing the fields on the Details Section, move them to the Group Header section

-Abhilash

abhilash_kumar
Active Contributor
0 Kudos

Another way to do this is to go to the Section Expert > highlight the details section > Click the formula button beside 'Suppress' and use this code:

stringvar s := {UserID};

Replace(s, totext(val(StrReverse(s)),0,""),"") = Replace(Previous({UserID}), totext(val(StrReverse(Previous({UserID}))),0,""),"")

-Abhilash

Former Member
0 Kudos

That worked perfectly! I did try with the grouping solution but it didn't quite seem to work (more than likely user error). However the second option is exactly what I am after.

Thank you so much!

Answers (0)