Fixes plus query to work with multiple ranges