Work in progress on database
More work on database.  Basic API in place
Merge Conflicts Fixed