Added file name to exception message and changed output data file header