more tests and query by id support