Implement more querying features
Merge commit '7472d3b'