Fix SQL errors report