using DAO for database persistence