fix for view database