Skip to main content
Announcements
Customer Spotlight: Discover what’s possible with embedded analytics Oct. 16 at 10:00 AM ET: REGISTER NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Help with a expression

Hi

I have this expression 

 

 

sum

(aggr(sum(Time_Per_Day)*count(distinct Date), Date,OrderTxt, OrderID,CustomID) / 60)

How do I add so it only do the calculation for max(OrderID) for each CustomerID and DeparmentNr?

Today it sometimes gets wrong beacuse if a order are changed the first are not removed, instead a new are created and I only want to sum the time for the latest order

Please let me now if I should give a better context.  

Edit: maybe hard to read in above textbox

sum(aggr(sum(Time_Per_Day)*count(distinct Date), Date,OrderTxt, OrderID,CustomID) / 60)

0 Replies