Forum Discussion
line graph including time difference as y axis
Hi v-yulgu-msft,
So I need to split start_on and end_on to get the date and time to be used on line graph?
Hi sclencioco,
I noticed that there is a column named as [time diff] in source table, you could convert its values from HH:MM:SS to integer (seconds/hours/minutes).
To add date values on X-axis, you could extract the date part from date/time first.
Regards,
Yuliana Gu
- sclencioco9 years ago
Helper I
Hi v-yulgu-msft,
I created [time diff] as MEASUREMENT. How can I make it an integer? Using Data type will do?
Thank you.
Saldie
- v-yulgu-msft9 years ago
Microsoft Employee
Hi sclencioco,
Not sure how you created the measure for [time diff]. But you could try this to calculate the time difference in hours/minutes/seconds.
Hour diff = DATEDIFF(MAX(Table_name[START_ON]),MAX(Table_name[END_ON]),HOUR)
Minute diff = DATEDIFF(TMAX(able_name[START_ON]),MAX(Table_name[END_ON]),MINUTE)
Second diff = DATEDIFF(MAX(Table_name[START_ON]),MAX(Table_name[END_ON]),SECOND)
Regards,
Yuliana Gu - v-yulgu-msft9 years ago
Microsoft Employee
Hi sclencioco,
Have you resolved the problem now? If so, would you please kindly mark the corresponding reply as an answer or sharing your resolution so that it can benefit more users? If you still have any question, please feel free to ask.
Regards,
Yuliana Gu