On Sun, 2002-02-03 at 14:07, Derek Atkins wrote:
> Dave Peticolas <[EMAIL PROTECTED]> writes:
> 
> > > For example, I want a query to be:
> > > 
> > >         a && (b || (c && d))
> >
> > To ensure grouping in a complicated expression, it's
> > best to combine two simpler queries together with
> > xaccQueryMerge. So you might create the query for
> > c && d, and a query for 'b', and combine them, and
> > then combine the resulting query with one for 'a'.
> 
> Ok, if I'm going to create the query for, e.g. c AND d,
> what's the right way of doing that?  In particular, I
> only want one logic operator, but I have to supply one
> with each term.  Do I need to create both the 'c' and
> 'd' terms with AND, or do I put 'OR c' and 'AND d', or
> is there something else what I'm missing?

The operator for the very first term in a query is ignored.
So you choose QUERY_AND when you add the second one and you
should get what you want.

dave

Attachment: signature.asc
Description: This is a digitally signed message part

Reply via email to