Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I want to calculate the following data in Data manager, but fail to get the answer, How to improve this expression?
@My_Rebecca Could you please post the current expression that you are currently using?
Set analysis is for evaluation in front end charts only,
I would suggest you create a calculated dimension as below
fieldname = if(SpecialStockNumber<>'E',SalesDocument&SalesDocumentItem ,null())
then in charts use measure
=Count(distinct fieldname )
@sidhiq91 Please refer to this express, thanks.
Count({<[DC TJ Inventory.Special Stock]<>'E'>}[DC TJ Inventory.Material])+count(distinct([DC TJ Inventory.Sales document]&[DC TJ Inventory.Sales Document Item]))
@vinieme12 It works at sheet edit, not Data Manager, because it seems that "Distinct" does not work at Data Manager.
if you want to use aggregation functions during data loading you need to use group by as well
Choose the "Data Load Editor " instead of "Data Manager"
example
Temp:
Load field1,field2,MeasureField1
From SomeDataSource;
Main:
Load field1,count(Distinct MEasureField1) as newField
Resident Temp
Where field1<>'Something'
Group by field1;
Or the same thing can just be calculated in chart as below
Temp:
Load field1,field2,MeasureField1
From SomeDataSource;
In chart
Dimension = field1
Measure = count({<field1-={'Something'}>}distinct MeasureField1)
@vinieme12 thanks for your support, I get your point.