cancel
Showing results for 
Search instead for 
Did you mean: 

changing dimension

Former Member
0 Kudos

Hi,

I have a report in which I have a customer name which has got changed from last month. If I want to display in a cell this customer name for latest date how do I do that? How to write the formula for this?

Basically this cell should display customer name for latest date available in data provider.

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Create a Flag object =If Date = Max(<date> In Body) In Report Then 1 else 0

In your cell : = <Customer Name> Where ( Flag = 1 )

Former Member
0 Kudos

Cpould you please help me with correct syntax for flag object since it is not accepting the formula. Highlighting syntax error at "Then"

Former Member
0 Kudos

Try =If Date =(Max(<date> In Body) In Report) Then 1 else 0

It works for me

Former Member
0 Kudos

This syntax is working FLAG= If < Date>=Max(< Date>) Then 1 Else 0 but it is not working when I try to display in another variable =Customer where FLAG=1.

Former Member
0 Kudos

are you gettting multivalue error?

What if you use Max operator around it?

Former Member
0 Kudos

It shows syntax eror.And if I check the listofvalues for the flag it shows no values in it.

Former Member
0 Kudos

THere is no LOV because this variable is an aggregate. Also the Where clause wont work in your example as it should be

=Measure Where (Dimension = unique value)

As I dont know what kind of objects you have (Dimensions, Measures / Date, Character , Number etc) its difficult to tell you which route to take.

Another option is to create a table with just the Date object.

Add a column with = If <Date>=(Max(<Invoice Date> In Body) In Report) Then <Sales Person>

This will give you the result you after. Place this in the footer of the table, go to format table and fold it. THis now only shows you the footer with your required result. You can hide the Date column or format it so its invisable.