alarm db & cursor close