Some more work on editing queries.