I have blended 2 datasets, joining them by a couple of keys. The left dataset contains data for most of the dates, while the second one has monthly sales goals for each salesman. So, I'll have the daily sales, which when summed up, they give me the total, but when I sum the sales goals from the right dataset, it gets repeated for each sales person occurrence in the left one, giving me the wrong result. If I put it on a table visual and set its calculation to Average, it gives me the correct sales goal for each person, but the total is wrong and if I put it on a KPI visual, the total is also wrong.
Any help is appreciated.
Thank you!
Sorry, it is not possible to have the same field aggregated as average first and in the next step sum over these average values.
For the total of the "sales goal" can be extracted from right dataset.
If your data comes from Big Query, you could do following steps:
count(orders) over (partition by salesmen, month_column)