Multi_Match filter by _type?

I have an index created by the JDBC river that contains types of objects:

Orders, Accounts etc.

If I execute the boosted multimatch query below I get back 50 of each type
of result. All is well.

However I'm trying to give the option to filter the list by user control
and lets say i only want to search one type or ... as many as I want.

I tried using Filtered but couldn't get the syntax to work for me.

Thanks for you help.

"query": {
"multi_match": {
"fields": [
"query": "mysearch",
"type": "best_fields",
"use_dis_max": "false"

"from": 0,
"sort": [],
"size": 50,
"aggs": {
"top-types": {
"terms": {
"field": "_type"
"aggs": {
"top_type_hits": {
"top_hits": {
"size": 50

Please update your bookmarks! We have moved to

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
To view this discussion on the web visit
For more options, visit