adding support for query
remove stale inspect element
Now using rid to work on records