I'm trying to find a difference between current & previous value of AOV (Avg value) which have the same unique ID (country). Right now my query gets the difference but doesn't respect the unique IDs. Any help or suggestion would be great!!
Query
index=test source=orders_prd_*
| dedup message.orderNo
| bin _time span=1h
| stats avg(message.orderTotal) as AOV by country _time | delta AOV AS Diff | eval OrderPercentage=(((Diff)/AOV)*100)
