Add more functions to DAOs and fix some exception bugs.
Create some views to test out the database.