GRAILS-11766 - improve where query chaining