Hello Enterprise DNA community -
hope someone can shed some light on what I may be doing wrong with my calculation below.
Thank you in advance!
Question - How to incorporate Date table dimension when using AllExcept in the fact table?
Intent - Attempting to find weekly transactions per productID.
Table 2 ('Transactions') = many values. (includes FacilityNM,DeviceNM,productID)
Table 1 (Date Table) = one value (using week number column)
WeeklyTransactions = CALCULATE(COUNTROWS('Transactions'),ALLEXCEPT('Transactions',**'Date Table'[Week Number]**,'Transactions'[FacilityNM],'Transactions'[DeviceNM],'Transactions'[productID]))
when i run calculation above, i get following result –
(sorry, I am unable to upload screenshot)
DeviceNM MedID TransactionDTS WeeklyTransactions Week Number
DeviceX 1243 11/1/2018 17:32 8 1
DeviceX 1243 11/1/2018 17:32 1 2
DeviceX 1243 11/1/2018 17:32 5 44
DeviceX 1243 11/1/2018 17:32 1 45
DeviceX 1243 11/1/2018 17:32 1 47
DeviceX 1243 11/1/2018 17:32 10 48
DeviceX 1243 11/1/2018 17:32 8 49
DeviceX 1243 11/1/2018 17:32 3 50
DeviceX 1243 11/1/2018 17:32 6 51
DeviceX 1243 11/1/2018 17:32 6 52
DeviceX 1243 11/1/2018 17:55 8 1
DeviceX 1243 11/1/2018 17:55 1 2
DeviceX 1243 11/1/2018 17:55 5 44
DeviceX 1243 11/1/2018 17:55 1 45
DeviceX 1243 11/1/2018 17:55 1 47
DeviceX 1243 11/1/2018 17:55 10 48
DeviceX 1243 11/1/2018 17:55 8 49
DeviceX 1243 11/1/2018 17:55 3 50
DeviceX 1243 11/1/2018 17:55 6 51
DeviceX 1243 11/1/2018 17:55 6 52
As you can see each week is being repeated for every date here vs. the week the date is in.