Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I need a sum of sales from associates whose SalesType is 'OutsideSales' **AND** if they have more than 10 rows of data.
SELECT
SUM(Sales)
FROM table
WHERE SalesType = 'OutsideSales'
HAVING COUNT(*) > 10
I have tried something like this...Not working:
Sum({<SalesAssociate = {'$(=Count({<SalesType = {'OutsideSales'}>} SalesId) > 0)'}>}Sales)
Just in case you're trying this in the script: set analysis cannot be used in the script.
But if you're trying to use the expression you posted in a chart then try this one:
Sum({<SalesAssociate = {"=Count({<SalesType = {'OutsideSales'}>} SalesId) > 10"}>}Sales)
Just in case you're trying this in the script: set analysis cannot be used in the script.
But if you're trying to use the expression you posted in a chart then try this one:
Sum({<SalesAssociate = {"=Count({<SalesType = {'OutsideSales'}>} SalesId) > 10"}>}Sales)
Works great. Thank you!