Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Challenge #4:
Our company manages sales from our sales reps. In order to see how they are performing at their last day of sale, we want to see those numbers. This means we want the total sales of their sale date for each sales rep. Check the outcome for the numbers that are needed, also the Totals need to be included.
If you have a solution, please post this in the comments as other people can learn from your solution!
So you have series of challenges. Are these your problems, or just challenges for others to try out? Coming back to your challenge/issue, I got your sample file attached. What is expected output there now (because I see the numbers are same in your sample and need-to-be screenshot)?
These are challenges for others to try to figure them out!
In the application you can find two tables:
The idea is to recreate the outcome table with the data from the challenge table. The challenge in this one is the maximum date of each sales rep while they are not the same.
FirstSortedValue( Aggr(Sum(Amount), SalesRep, Date), -Date)
Can this be done using aggr or some other way? i tried using aggr but as set analysis works column wise and not row wise , I could not get it working.
@JordyWegman , Thanks for sharing the challenge its quite fun to attempt something like this
Correct, that is also the challenging thing about this! You can check the post of @tresesco .
Another solution using set analysis you can try like:
Sum({<Date={"=Date(Aggr(Max(Date),SalesRep))"}>}Amount)
Works really well.
Any reason why you have included Date within the $ sign expansion ? (formatting?)
sum({<Date={"=(aggr(max(Date),SalesRep))"}>}Amount) seems to work fine as well
I never checked that the Date field here was actually numeric. I thought a date field would have date format values, and to be on the safer side if format comes into spoil the expression, I just added to make it safe-working.
By the way, there is no $ sign expansion here.
Hereby the solution!