Added offline querying