db overhaul
resolved merge conflicts