stated building db and assiciated model