Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have a straight table with dimensions Company, Date, Yd Date
Expressions : Cost , Yd Cost
I am having trouble displaying Yd Cost.
Company, Date, and Cost come from the same table but Yd Date comes from a different table and is joined by Date field. I tried set analysis:
sum({<[DATE]= {'$(=Date(max({<[YD DATE] = {"<$(=max([DATE]))"}> } [YD DATE])))'}>} COST)
The idea was for it to pick the max YD DATE which is less than DATE but it doesn't work. I would like to see a list of dates but with using MAX it will only display one record.
try this
=sum({<[YD DATE]= p({$<max([YD DATE]) = {"<$(=max([DATE]))"}> } [YD DATE])>} COST)
or this
=sum({<[YD DATE]= p({$<max([YD DATE]) = {"<max([DATE])"}> } [YD DATE])>} COST)
Gives syntax error and when that's changed, just zeros ![]()
Check with this
=sum({<[DATE]={"=[DATE]<[YD DATE]"}>} COST)
Thanks.
If I change < to > like this:
=sum({<[DATE]={"=[DATE]>[YD DATE]"}>} COST)
Then costs are displayed but for [DATE], not [YD DATE]
Would it be possible to show costs for max YD DATE excluding DATE?
not clear. can you explain clearly if possible with some examples.
COMPANY DATE COSTS YD DATE YD COSTS
ABC 16/01/2013 2000 17/01/2013 1900
ABC 17/01/2013 1800 16/01/2013 2000
This is what it should look like. I can't get YD COSTS. If I use
=sum({<[DATE]={"=[DATE]>[YD DATE]]"}>} COST)
Then I get this:
COMPANY DATE COSTS YD DATE YD COSTS
ABC 16/01/2013 2000 17/01/2013 2000
ABC 17/01/2013 1800 16/01/2013 1800
YD COSTS are not right
I need to get YD COSTS for YD DATE.