Serial Differencing where operand records are returned

Is there a way for elasticsearch to look at the documents, perform subtraction on a single field (similar to serial difference) and get two specific records that produced a difference that exceeds a defined threshold? Let me give an example...

Let's say I have 100 records, all with date fields. I want to do serial differencing on all these date fields and get the 2 documents where, let's say, the difference exceeded 1 hour.

Is there an 'easy' way for elasticsearch to do this? If none, is there a 'hard' way of doing it? Thanks in advance.

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