Forum Discussion
Anonymous
5 years agoNot applicable
Compare hour from different table
Hi all I have a column Dim Hours, that contains 24 hours . table a and I have other column in other table that contains some hours for exemplo table b 12:00:00 12:30:00 17:00:00 ...
amitchandak
Super User
5 years agoAnonymous , do these tables has any thing in common.
Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.
You can actually create a new column in the required table. and then use that for you calculations.
Example in video - https://www.youtube.com/watch?v=czNHt7UXIe8
- Anonymous5 years agoNot applicableThanks a lot,
with this cod I could solve my problem, make a looping comparind the datas from the tables
Hora Cor Parada =var selecthora = SELECTEDVALUE(E_DIM_HORA[HORA])var result =CALCULATE(SELECTEDVALUE(Fato[HoraInicio]),FILTER(Fato,selecthora >= (Fato[HoraInicio])&&selecthora <= Fato[HoraFim] ),Fato[MOVIMENTO] = "2")returnIf(result,1,0)