implemented db storage