fix visit & visit lines sql views