Ignore leading whitespace in get_one_query(). Fixes TODO item.
Add regression test case for whitespace.