Switched to OOP in database.