Return shared queries in order of accessed time(with tests
Merge pull request #91 from cbmi/issue-87

Return shared queries in order of accessed time