fixed query string formatting