Writing query for customer acquisition funnel analysis


(ADIL BURAK KILIC) #1

Hi,

We have an event-event based index and we want to do funnel analysis for the users.

GETevents/_search
{
"size": 0,
"aggs": {
"funnel": {
 "filters": {
 "filters": {
 "totalInteractions": {
 "query_string": {
 "query": "page:\"https\\:\\/\\/www\\.mywebsite\\.com\\/\""
 }
 },
 "buttonClicks": {
 "query_string": {
 "query": "name:button_clicked AND data.link_id:homepage-cta-1",
 "analyze_wildcard": true,
 "default_field": "*"
 }
 },
 "userSignUp": {
 "query_string": {
 "query": "name:user_signup",
 "analyze_wildcard": true,
 "default_field": "*"
 }
}
}
   },
    "aggs": {
      "Unique": {
    "cardinality": {
   "field": "distinct_id.keyword"
    }
   }
     }
      }
 }
}

But it's not chaining the queries so the result is wrong. How can I write a chained query for this funnel?


(system) #2

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