latest db is set before analysing