Sorry. I don't follow. Are you talking about _type field or do you have a type 
field in your docs?


-- 
David Pilato | Technical Advocate | elasticsearch.com
[email protected]
@dadoonet | @elasticsearchfr | @scrutmydocs



Le 24 septembre 2014 à 10:01:39, [email protected] ([email protected]) a 
écrit:

{
   "took": 9247,
   "timed_out": false,
   "_shards": {
      "total": 232,
      "successful": 232,
      "failed": 0
   },
   "hits": {
      "total": 7545866876,
      "max_score": 0,
      "hits": []
   },
   "aggregations": {
      "by_type": {
         "buckets": [
            {
               "key": "type1",
               "doc_count": 6437248697
            },
            {
               "key": "type2",
               "doc_count": 1077175717
            },
            {
               "key": "type3",
               "doc_count": 31442462
            }
         ]
      }
   }
}

That count in "type1" is the total including "other values" so it appears that 
the "type:" or "_type:" fields are screwed somehow?
The total doc_count is right but with those "other values".....

On Wednesday, September 24, 2014 8:48:59 AM UTC+1, David Pilato wrote:
o_O 

What does this give?

curl -XGET "http://192.168.59.103:9200/index/_search"; -d'
{
  "size": 0, 
  "aggs": {
    "by_type": {
      "terms": {
        "field": "_type"
      }
    }
  }
}'



-- 
David Pilato | Technical Advocate | elasticsearch.com
[email protected]
@dadoonet | @elasticsearchfr | @scrutmydocs



Le 24 septembre 2014 à 09:39:47, [email protected] ([email protected]) a 
écrit:

Thanks for your help with this. I appreciate it.

Here is the result of that query:

{
   "took": 5251,
   "timed_out": false,
   "_shards": {
      "total": 232,
      "successful": 232,
      "failed": 0
   },
   "hits": {
      "total": 0,
      "max_score": null,
      "hits": []
   }
}



On Wednesday, September 24, 2014 8:11:25 AM UTC+1, David Pilato wrote:
You could try to run this:

curl -XGET "http://localhost:9200/index/_search"; -d'
{
  "post_filter": {
    "not": {
      "filter": {
        "or": [
          {
            "term": {
              "_type": "type1"
            }
          },
          {
            "term": {
              "_type": "type2"
            }
          },
          {
            "term": {
              "_type": "type3"
            }
          }
        ]
      }
    }
  }
}'


--
You received this message because you are subscribed to the Google Groups 
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/elasticsearch/12393554-3306-4fc3-80b2-4005071f0daf%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups 
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/elasticsearch/bf0e674e-e9a2-49cd-9bfc-21d5a941bc89%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/elasticsearch/etPan.54227ace.1befd79f.3194%40MacBook-Air-de-David.local.
For more options, visit https://groups.google.com/d/optout.

Reply via email to