SQL database - corrections