Forum Discussion
Measure counting products with test on date
- 8 years ago
Hi marcp
I am a bit new to this, and there is probably a more straight-forward way. I suggest the following steps:
Make a query from table 2
merge table 1 based on item
expand columns to include the ref date
Add a column that says "Keep" if the date-sale is >= ref date or "Drop" otherwise
Filter the new column to keep the "Keep" values
Group by date-sale and item, making a column called measure1 that counts rows
I think that should get you where you want to be.
kingcondie
Hi marcp
I am a bit new to this, and there is probably a more straight-forward way. I suggest the following steps:
Make a query from table 2
merge table 1 based on item
expand columns to include the ref date
Add a column that says "Keep" if the date-sale is >= ref date or "Drop" otherwise
Filter the new column to keep the "Keep" values
Group by date-sale and item, making a column called measure1 that counts rows
I think that should get you where you want to be.
kingcondie
- marcp8 years ago
Helper I
Hi
Thank you very much Kingcondie !
It works fine
I can't share proprietary datas but your method solved my issue :)
Regards
Marc
- marcp8 years ago
Helper I
Hi Kingcondie
Thank you for your answers. This method makes sense. I’ll try it on Monday.
I wonder if a magic Dax formula can do it too.
Regards
Marc