refact database