added online querying