Forum Discussion
Difficult Measures
- 7 years ago
Once again, I highly recommend against using the first visual solution I was able to create. I've created a 2nd matrix in the report that's a better way of working with the data, though still not as good as starting to record the source or adding in 3rd party orders to the original moving forward.
Here's the file: https://drive.google.com/open?id=16uxhevNcQQxO8gUSBclpupGBTHYDhpQV
A test file is in my post.
The original data which is in excel, is really big and contains sensitive data.
This data is also a little bit more complex to explain how everything works.
You need some sort of indicator that tells what source the product comes from. What indicates that it came from a third party?
- marsclone7 years ago
Helper IV
That’s a problem, from the products that leaves the warehouse, it is not known where they from, own production or bought from third parties.
But when i calculate the total sales from our trade companies minus the products which are made by our self i have the total buying from third parties.
An ugly measure i believe?
- Cmcmahan7 years ago
Resident Rockstar
So the only way to check if a product is A, B, or 3rd party is to go to the dataset of products made by A, the dataset of products made by B, and make sure that a specific item is not in either list?
Easiest way sounds like it would be to identify and mark every item as either from A, or B, and then the rest MUST be from 3rd parties.
Source = IF( CONTAINS('AProducts', 'AProducts'[itemID], SELECTEDVALUE('WarehouseProducts'[ItemID])), "A",
IF( CONTAINS('BProducts', 'BProducts'[itemID], SELECTEDVALUE('WarehouseProducts'[ItemID])), "B",
"Third Party"
)
)- marsclone7 years ago
Helper IV
The unique item per factory is the location, same products are produced by all factories.
All Sales data from all factories and trade companies are in the same table.
I think the measure you showed is not working for this data table?
The Measure would be like:
Sum all sales (quantity) trade companies -/- Sum sales Factory A -/- Sum sales Factory B = Source Third Parties