Fix database storage