Searching over multiple untouched fields without "_all"

Hi there,

I´m new to Elasticsearch.

I tried to search over multiple untouched fields with the following query:

{
"from" : searchPageNumberFTS,
"size":10,
"sort":{},
"query":[ {
"filtered" : {
"query" : {
"wildcard" :
{ "Product.untouched":searchTextFulltextSearch}

} ,
"filter": {
"or":[
{
"query": {
"wildcard": {
"Test.untouched": "*"
}
}
}
]
}
},"filtered" : {
"query" : {
"wildcard" :
{ "Project.untouched":searchTextFulltextSearch}

} ,
"filter": {
"or":[
{
"query": {
"wildcard": {
"Test.untouched": "*"
}
}
}
]
}
}
}]
};
But the 1st query was overwritten! It resolves as :

  1. {"from":0,"size":10,"sort":{},"query":[{"filtered":{"query":{
    "wildcard":{"Project.untouched":"CRI**1"}},"filter":{"or":[{"query":{
    "wildcard":{"Test.untouched":"*"}}}]}}}]}:

is there any posiblility to search over more the one untouched field ?

Greetings
ND

--
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 elasticsearch+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

You need to combine the different queries with a bool query instead of
creating an array of queries:

Also, are you sure you want to use a query filter that is essentially a
match all? Not sure what you heop to achieve, but perhaps the exist filter
might be more appropriate:

Cheers,

Ivan

On Wed, Nov 13, 2013 at 6:18 AM, Nd Coderific
andreas.coder@googlemail.comwrote:

Hi there,

I´m new to Elasticsearch.

I tried to search over multiple untouched fields with the following query:

{
"from" : searchPageNumberFTS,
"size":10,
"sort":{},
"query":[ {
"filtered" : {
"query" : {
"wildcard" :
{ "Product.untouched":searchTextFulltextSearch}

} ,
"filter": {
"or":[
{
"query": {
"wildcard": {
"Test.untouched": "*"
}
}
}
]
}
},"filtered" : {
"query" : {
"wildcard" :
{ "Project.untouched":searchTextFulltextSearch}

} ,
"filter": {
"or":[
{
"query": {
"wildcard": {
"Test.untouched": "*"
}
}
}
]
}
}
}]
};
But the 1st query was overwritten! It resolves as :

  1. {"from":0,"size":10,"sort":{},"query":[{"filtered":{"query":{
    "wildcard":{"Project.untouched":"CRI**1"}},"filter":{"or":[{"query":{
    "wildcard":{"Test.untouched":"*"}}}]}}}]}:

is there any posiblility to search over more the one untouched field ?

Greetings
ND

--
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 elasticsearch+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

--
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 elasticsearch+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.