fixes for handling multiple query options