Glad you got it working ![]()
Not for a range query, no. You could write a script query to do this but similarly to script sorting, the performance of the query would not be as good as using the range query, but the performance might be acceptable for your use case. You can write a compound query however that combines
- a 
rangequery onshipment_datewith atermquery on thesale*_index(both asfilterclauses in aboolquery) 
with
- a 
rangequery oncreated_datewith atermquery on theorder*_index(both asfilterclauses in aboolquery) 
both as should clauses in a bool query. Here's something similar as an example.