cancel
Showing results for 
Search instead for 
Did you mean: 

comparing fields

Former Member
0 Kudos

i am creating an audit report and i need to display in the report if my next field <> next field

AP-231SH BULKJ NEOFLON PFA AP-231SH

AP-231SH BULKJ Test 9/26/.08

how do i have it stop on the group so when it hits another item group it should only compare within that group.

i want to surpress the records that are the same and only display what has changed.

unfortunatley we dont have audit tables

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

You need to use the previous function more than once in this case.

To ensure the comparison doesn't occur over a group boundary, you can simply check for the grouping condition. If we assume that the data is grouped based on a field called 'identifier', and you want to conditionally supress a field called 'name' if it's repeated.

In the formatting for the field, but in a conditional supression formula that looks something like this:


//check if we've changed groups
IF(previous(<identifier>) = <identifier> THEN
   //if we haven't supress duplicated fields
   previous(<name>) = <name>
ELSE false

remembering that conditional formatting fields need to evaluate to true or false,

Hope that helps.

Former Member
0 Kudos

thank you, This is what i ended up using.

if {PR_PROD_HIST_RPT;1.PRODUCT_KEY}=previous({PR_PROD_HIST_RPT;1.PRODUCT_KEY})and

({PR_PROD_HIST_RPT;1.PROD_DESC})<>previous( {PR_PROD_HIST_RPT;1.PROD_DESC})

then {PR_PROD_HIST_RPT;1.PROD_DESC} else ""

Former Member
0 Kudos

Hi Sharon,

Can you please try the following syntax in the formula,

If <> previous() then

Statement; ' Compare Statement.

Hope this might help you.

Regards,

Vinay