fix query for conjuctions