done coding adding to database
not tested yet