edited database script