more preliminary database work