[PATCH] sc: Add support for the 'query' command.