Subtract values for consecutive events

Hi,

A newbie question
Version:
ES - 5.6.2
Kibana - 5.6.2
Logstash - 5.6.4
I have following data pulled from MySQL database using JDBC input
There are multiple meters with unique meter ID.

Time                            value       MeterID         id  
July 28th 2018, 23:30:00.000	10,831.872	16200747	596,157
July 28th 2018, 23:15:00.000	10,831.626	16200747	596,148
July 28th 2018, 23:00:00.000	10,831.283	16200747	596,139

I need to display & calculate the consumption for the all the MeterIDs and also for each meterid, lets say hourly or daily something like
[value - value(1 hour before)]
[value - value(1 day before)]
Now i need to know what should be best way to achieve this through logstash or kibana

Thanks

Look at the aggregate filter.

Hi @Badger,

Thanks for your response, however i would really appreciate if you could outline an example with my use case.

Is your data sorted by MeterId? If they are, then follow example 4. If not I would follow example 5.

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