Forum Discussion
Creating a new table from 2 others with a calculation
- Anonymous6 years ago
PatrickByGecko - You could create the following Calculated Table in DAX:
New = ADDCOLUMNS(Dates, "Nbr Male", COUNTROWS( FILTER( ALL(Workers), Workers[DateEntry] <= Dates[Date] && Workers[Sex] = "male" ) ), "Nbr Female", COUNTROWS( FILTER( ALL(Workers), Workers[DateEntry] <= Dates[Date] && Workers[Sex] = "female" ) ) )
I did put some "(" the best I can, but only the first row is completed I mean when date=_DateBegin.
PatrickByGecko - Can you please check some particular dates that are known to have data and let me know whether they have data for the Measure?
- Anonymous6 years agoNot applicable
PatrickByGecko - The problem is the column [DATE ENTREEE] contains Date + Time information. Therefore, it does not contain exact matches with the date table, which is Date only.
You could create a new column like this:
Date2 = INT(Collaborateurs2[DATE ENTREEE])Then use the new column in the Relationship and in the DAX, instead of [DATE ENTREEE]
I hope this helps. If it does, please Mark as a solution.
I also appreciate Kudos. - PatrickByGecko6 years ago
Helper V
Yes there is data as you can see. The problem is somewhere else because at this time I get no value at all for each counter...
😞
There is no value in the counters even when there is no test on "category"..
- Anonymous6 years agoNot applicable
PatrickByGecko - Would it be possible to share your pbix file?
- PatrickByGecko6 years ago
Helper V
Of course. I did an extract and the effect is the same.
Here it is => https://we.tl/t-9QoLPrU5KF
- PatrickByGecko6 years ago
Helper V
It is working Thanks a lot Natel.
Patrick.