Changed grade school to eliminate db reader

Changed everything to only consider the sorted way of accessing the database. Called this access to_hash.

Fixes #1275
Merge pull request #1279 from markijbema/upgrade-gradeschool

Changed grade school to eliminate db reader