Lots of work towards a better database schema