Splunk Search

How to get data by a field when not using stats

xvxt006
Contributor

Hi,

I am trying to get conversion and average order value and i am using eval function to calculate these. But i want to get these by different applications that we have. If i don't use stats i don't know how to get by application. If i use stats what function to use to just get the evaluated values? i tried values but did not work.

| stats dc(OrderNumber) as Orders, dc(sessionid) as Visits | eval CVR =(Orders/Visits)*100 | eval Conversion = round(CVR, 1) | eval AOV=(Revenue/Orders) | eval AOV = round(AOV, 1) | stats values(AOV), values(Conversion) by Application

Tags (1)
0 Karma
1 Solution

_d_
Splunk Employee
Splunk Employee

| stats dc(OrderNumber) as Orders, dc(sessionid) as Visits by Application | eval CVR =(Orders/Visits)*100 | eval Conversion = round(CVR, 1) | eval AOV=(Revenue/Orders) | eval AOV = round(AOV, 1)

View solution in original post

_d_
Splunk Employee
Splunk Employee

| stats dc(OrderNumber) as Orders, dc(sessionid) as Visits by Application | eval CVR =(Orders/Visits)*100 | eval Conversion = round(CVR, 1) | eval AOV=(Revenue/Orders) | eval AOV = round(AOV, 1)

rechteklebe
Path Finder

Try to use 'eventstats' instead of the first stats.

0 Karma

xvxt006
Contributor

Hi Below solution from d worked for me. I will try evenstats also and see if it works.

0 Karma
Get Updates on the Splunk Community!

Observability | Use Synthetic Monitoring for Website Metadata Verification

If you are on Splunk Observability Cloud, you may already have Synthetic Monitoringin your observability ...

More Ways To Control Your Costs With Archived Metrics | Register for Tech Talk

Tuesday, May 14, 2024  |  11AM PT / 2PM ET Register to Attend Join us for this Tech Talk and learn how to ...

.conf24 | Personalize your .conf experience with Learning Paths!

Personalize your .conf24 Experience Learning paths allow you to level up your skill sets and dive deeper ...