fixes the example and breaks up cmd/query in the docs