updated database filling script

I haven't verified that everything references each other correctly, but
if you just want to verify that the databases can be filled, this'll do
that. I'll 100% this script over the weekend