I have a parent database with parent type "testdata" and child type
"testfield". I am running the below query with search type
"dfs_query_then_fetch" means i am getting the below exception. If i
run with default search type, i am getting the result successfully.
curl -XGET 'http://localhost:9200/dbtest/testdata/_search?
search_type=dfs_query_then_fetch' -d '{"query" :{ "bool" :
{ "must_not" : [{ "has_child" : {"type" : "testfield", "query" :
{ "bool" : { "should" : [{ "query_string" : { "default_field" :
"fieldname","query" : "fieldname:*","default_operator" :
"OR","analyzer" : standard","allow_leading_wildcard" :
true,"lowercase_expanded_terms": true,"enable_position_increments" :
true,"fuzzy_prefix_length" : 0,"fuzzy_min_sim" : 0.5,"phrase_slop" :
0,"boost" : 1.0 } }] } }} }] } }, "from" : 0, "size" : 20, "explain" :
false}'
{"error":"ReduceSearchPhaseException[Failed to execute phase [fetch],
[reduce] ; shardFailures {[uAXwvLCWQPqiy9Nn1Psq_g][db555][0]:
QueryPhaseExecutionException[[db555][0]: query[-
ConstantScore(child_filter[textfield/metadata](filtered(fieldname:*)-
FilterCacheFilterWrapper(_type:textfield)))
+ConstantScore(:)],from[0],size[20]: Query Failed [Failed to execute
child query [filtered(fieldname:)-
FilterCacheFilterWrapper(_type:textfield)]]]; nested: }
{[uAXwvLCWQPqiy9Nn1Psq_g][db555][1]:
QueryPhaseExecutionException[[db555][1]: query[-
ConstantScore(child_filter[textfield/metadata](filtered(fieldname:)-
FilterCacheFilterWrapper(_type:textfield)))
+ConstantScore(:)],from[0],size[20]: Query Failed [Failed to execute
child query [filtered(fieldname:)-
FilterCacheFilterWrapper(_type:textfield)]]]; nested: }
{[uAXwvLCWQPqiy9Nn1Psq_g][db555][2]:
QueryPhaseExecutionException[[db555][2]: query[-
ConstantScore(child_filter[textfield/metadata](filtered(fieldname:)-
FilterCacheFilterWrapper(_type:textfield)))
+ConstantScore(:)],from[0],size[20]: Query Failed [Failed to execute
child query [filtered(fieldname:)-
FilterCacheFilterWrapper(_type:textfield)]]]; nested: }
{[uAXwvLCWQPqiy9Nn1Psq_g][db555][3]:
QueryPhaseExecutionException[[db555][3]: query[-
ConstantScore(child_filter[textfield/metadata](filtered(fieldname:)-
FilterCacheFilterWrapper(_type:textfield)))
+ConstantScore(:)],from[0],size[20]: Query Failed [Failed to execute
child query [filtered(fieldname:)-
FilterCacheFilterWrapper(_type:textfield)]]]; nested: }
{[uAXwvLCWQPqiy9Nn1Psq_g][db555][4]:
QueryPhaseExecutionException[[db555][4]: query[-
ConstantScore(child_filter[textfield/metadata](filtered(fieldname:)-
FilterCacheFilterWrapper(_type:textfield)))
+ConstantScore(:)],from[0],size[20]: Query Failed [Failed to execute
child query [filtered(fieldname:*)-
FilterCacheFilterWrapper(_type:textfield)]]]; nested: }]; nested:
IndexOutOfBoundsException[index (0) must be less than size (0)];
","status":500}
Can any one help me....