Effective Date

I have 10 columns in my report. I will have to create 9 parameters (using 9 fields/columns). Another column is Effective Date. Users will provide input for 9 parameters and it may give rows which are same but with different date. In that case, it should only print the latest date which is the effective date.

In a simpler way, if the value of [Parameter 1] + [Parameter 2]…+[Parameter 9] Then [take the latest date]

Ho can I write this in Crystal Reports ?


Developer_Designer (BOB member since 2009-08-09)

In a formula do a long winded IF concatenation.

IF [Parameter 9] =
Then [Parameter 9]
Else
If [Parameter 8] =
Then [Parameter 8]
Else
If [Parameter 7] = …

Effectively working backwards through your parameter and picking the last one used.

The only more elegant solution I can think of is drop parameter values into an array along with a consecutive number, take the last element out of the arrary. More complicated and not necessarily faster.


KMB :uk: (BOB member since 2004-02-11)