Formula to calculate time interval between queries

Hi Community, i would like to know how to set up a formula so that i can calculate the time interval / time ellapsed between queries raised on a certain product.
If we consider a “Product A” which has two queries raised related to it how can i know the time interval between the two queries.
The link will shows the example of what the table looks like for the above mentioned example.

Hi @VINAY_B_C :blush: !

I’ve modified you sample doc (thanks for sharing :raised_hands: ) and added a single select relation field to your table Table :blush: (the relation field is linked to the table Table).

The relation field is meant to return either the previous row in the table depending on the product in the field [product name] and the date in the field [Query raised on] or, if a query is the very first made for a product, it will return thisRow (as in this case, there would be no previous row to find).

Then, in the field [Time Gap / Interval between queries], I’ve used this formula :

thisRow.[Query raised on] - thisRow.[Previous row].[Query raised on]

… to return the time elapsed between 2 queries for a product :blush:, which subtracts the value in the field [Query raised on] for the row referenced in thisRow.[Previous row] from thisRow.[Query raised on] .

I’ll admit I’m not entirely sure if this is what you wanted to calculate though :sweat_smile: , but I still hope this will help you a little :innocent: .

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.