Hi @PaulaCom, Here's a way to convert your date to "Jan", "Feb" etc: strftime(date_field, format) see docs We can use the field Order_Date like this: eval month = strftime(strptime(Order_Date, "%d/%m/%Y"), "%b") That adds another step of converting the date to a unix timestamp, then converting that timestamp to the Month in english. Now that we have the month, we can make it a field by using special curly brackets: | eval {month} = Total That will create a field called "Jan" or "Feb" with the value of the total for sales. Here's the Search all together: |makeresults | eval data="Account_No=\"123\", Total=\"15.00\", Order_Date=\"1/01/2023\"@@Account_No=\"123\", Total=\"35.00\", Order_Date=\"15/02/2023\"@@Account_No=\"123\", Total=\"45.00\", Order_Date=\"19/02/2023\"@@Account_No=\"456\", Total=\"15.00\", Order_Date=\"1/01/2023\"@@Account_No=\"456\", Total=\"50.00\", Order_Date=\"25/01/2023\"@@Account_No=\"456\", Total=\"10.00\", Order_Date=\"19/02/2023\""
| makemv data delim="@@" | mvexpand data | rename data as _raw | extract
``` The above just creates the test data```
| eval month = strftime(strptime(Order_Date, "%d/%m/%Y"), "%b")
| stats sum(Total) as Total by Account_No, month
| eval {month}=Total
| fields - Total, month
| stats sum(*) as * by Account_No
| table Account_No, Ja*, Fe*,Ma*,Ap*,Ma*,Jun*, Jul*,Au*,Se*,Oc*,No*,De* The last table bit at the end is so that the months are listed in the right order. The result is: Hopefully that gets you closer to what you were looking for. Cheers, Daniel
... View more