ioException POI changes, read excel file

sLuintel
Giga Expert

Hello, i am kind of repeating myself... but hopefully someone help.

 

The issue is that I am receiving an error message as below:

 

IOException on file /glide/nodes/mhpdev001_16008/bin/../tmp/ids5ae7362a2b62650080d64c7605da1517.tmp, Invalid header signature; read 724303750490253372, expected -2226271756974174256

 

I also know that this issue is because the Excel file that is being imported was exported in a format other than a native Excel file (XML, HTML, etc.). I have try opening the Excel file (in Excel) and click File | Save As. Select the XLS file type. Try the import again using the "new" XLS file. and this works.


However, the problem is that this function is supposed to be automated function and we don't want somebody to manually get the export and save it as .xls and import it again. Is there a way where the POI will be able to read the file as .xls without having to manually save it and import it?

7 REPLIES 7

Albert13
Kilo Sage

Hi Sweeda,



Did you ever find a resolution to this issue.   I've just run across it myself with an automated soluton we're trying to implement?



Albert


Hi Albert, no we couldn't find a service now solution and concluded that the issue had to be resolved on the oracle sie, where we were receiving the extracts from. In my case, the file was a CSV file saved with the .xls extension. Excel was able to open it without a problem, but POI was not.


Sweeda,



I think I may have figured something out.   Need powershell installed on the midserver as well as excel (i put of excel 2010 on).   It's a bit of a process but but the short of it is I use code to open the fine and save it right way.   So far is seems to like the automated process.



Albert


Hi Sweeda Luintel&& Albert




Is there possibility to read Excel data attached to task/incident/change using script ?