Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

How to calculate endtimestamp for the event if only one date/time column available

Hi there,

 

I am in search for solution to my problem. I believe somebody must have had the same or similar situation therefore your help is greatly appreciated.

 

I have a table with one date column which consists of date and time and other rows specifiy the activity in the process, it is P2P.

 

Please find attached below what I have in white table and yellow is what I would like to have.

 

Capture.PNG

 

Many thanks

1 ACCEPTED SOLUTION

@Anonymous ,

 

It works on my side as below, could you please share the sample data for further analysis?

Capture.PNG 

 

Community Support Team _ Jimmy Tao

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
v-yuta-msft
Community Support
Community Support

@Anonymous ,

 

Create an index column in query editor and then create a calculate column using dax below:

Timestamp END =
VAR Current_Index = Table[Index]
RETURN
    CALCULATE (
        MAX ( Table[Timestamp START] ),
        FILTER ( Table, Table[Index] = Current_Index + 1 )
    )

Community Support Team _ Jimmy Tao

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Anonymous
Not applicable

Hi @v-yuta-msft 

 

Thank you for the tip. Although I do get the dates in the Timestamp END, the dates I get are the same as the Timestamp START.

 

Seems that the part with Current_Index + 1 does not work, or at least not as it should. Do you have an advice how to solve this? If needed, I can also provide an example excel sheet.

 

Many thanks

@Anonymous ,

 

It works on my side as below, could you please share the sample data for further analysis?

Capture.PNG 

 

Community Support Team _ Jimmy Tao

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.