• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

premature end of file

 
Ranch Hand
Posts: 91
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have an xml file called AR1048615.xml. I am trying to transform it using saxon. But during the transformation, it fails and gives me the following error:
Fatal error reported by XML parser: premature end of file (found "[EOF]")
URL: file:/work/vsubra/edi/saxon/AR1048615.xml
Line: 123
Column: 0
Error
premature end of file (found "[EOF]"): premature end of file (found "[EOF]")
Transformation failed
Error(s) in transforming the file AR1048615.xml
Line 123 is nothing but the last line /cxml
where the file is closed.
I dont see anything wrong in the xmlfile. How can I fix this
Thanks,
Vidhya
 
Ranch Hand
Posts: 1953
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Try to open your xml file in IE5.5 or up to see what it tells you.
 
vidhya subramaniam
Ranch Hand
Posts: 91
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Roseanne,
When i open the file in IE5.5 or higher , it doesnt give me any error. I tried to open it with a text editor and compare it with files that were working fine without any error , i found that there were some extra spaces between feww lines (may be 1 enter). is that the problem, because when i rmoved those extra spaces and save it it works fine. So how can i fix this error? ( kind of some script or something)
Thanks,
Vidhya
 
Ranch Hand
Posts: 5040
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
some extra spaces between feww lines (may be 1 enter). is that the problem,
I would highly suspect that there is a "carriage return" at line 123. I did see problems like this earlier. But unfortunately, in my application it is completely random (or so I think) and I can't reproduce it consistently to debug.
I would love to hear a fix for such things.
I tried using the "strip-space" thingy but it din't take me too long.
regds.
- madhav
 
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Even I have the same problem, couldn't fix. Any suggestions please?
PS: I removed all the empty spaces, carriage returns from the file. Still the SAX parser gives me the same error.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic