Throw when de-referencing a key that does not exist

Throw an error when trying to de-reference a key that does not exist in the database. The error prints which key is the culprit.