Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I want to understand the end date and start date of a transport in order to keep the transport with the start date which is before the end date. and calculate the time between the two thereafter.
Here is the graph with the negative durations that I want to delete them and the request that I typed and which did not work
if( (DATEFIN>DATEDEB), avg(Interval(DATEFIN-DATEDEB)))
Thanks
Try this
Avg({<Agent = {"=DATEFIN-DATEDEB > 0"}>} Interval(DATEFIN-DATEDEB))
thanks for your answer but it doesn't work for me
Would you be able to provide more details as to what is the issue? Did my expression throw an error message?
There is no syntax error, just negative durations always appear
The name of your dimension is Agent, right? Or is that a label? If it is a label, make sure to replace Agent with your actual dimension in the expression below
Avg({<Agent = {"=DATEFIN-DATEDEB > 0"}>} Interval(DATEFIN-DATEDEB))
Yes , it's agent
Would you be able to share an image where I can see the chart with the above expression? I can't think of a reason why this doesn't work, but may be I am missing something. Might help if you are able to share a sample where we can see this issue