Data written to file on sql connection error is not ignored anymore during runtime