query results depend on order of inputs
Description of problem
I want to make fairly complex queries to gracedb for example search for events with certain single inspiral attributes, specify the pipeline, search, creation time, and FAR. For example, the following query should return all gstlal AllSky injection uploads from MDC11 below a far threshold:
si.channel = "GDS-CALIB_STRAIN_O3Replay" | si.channel = "Hrec_hoft_16384Hz_O3Replay" pipeline: gstlal created: 2023-02-17 00:00:00 .. 2023-03-28 00:00:00 far < 1e-8 search: AllSky
But this query returns seemingly any gstlal upload regardless of FAR and single inspiral attributes. If I change the order, then it works as expected:
far <= 1e-8 & (si.channel = "GDS-CALIB_STRAIN_O3Replay" | si.channel = "Hrec_hoft_16384Hz_O3Replay") pipeline: gstlal search: AllSky created: 2023-02-17 00:00:00 .. 2023-03-28 00:00:00
Expected behavior
I would expect these queries to be order independent. And when there are multiple inputs given (ie FAR, pipeline, single inspiral attributes) I would expect them to all implicitly be joined by "AND" instead of "OR".
Steps to reproduce
Query with "wrong order": here
Query with "right order: here
Context/environment
Suggested solutions
Even if it's not possible/easy to make the queries more flexible in terms of order of options, it would be nice if the "rules" were documented so that users can look up how to write queries to get the expected results.