Implemented local database cache