corrected db script