added list_by_query function and udpated readme