finsihed database

finished and tested with small amounts of test data