It wasn't immediately obvious to me and it is not documented, but if you need to find eg all the tstests of a particular type under certain test sets and only those tstests with active defects when setting up your filter for the tstests you can make two calls to setXFilter, one for the TSTEST-TESTSET join and a second for the TSTEST-BUG join. The second call won't overwrite the first xFilter, but will append to it.

I made the mistake of trying to look for documentation first, rather than just giving it a go.

Have fun,
Brendan.