0

I have an RDF file named SEALTriples.nt and I am validating that using the command

riot.bat --validate SEALTriples.nt

It is throwing the following error:

ERROR [line: 15858, col: 82] Bad character encoding

When I went to the RDF file the line has no error; I am sure because I copied that line and used it in another RDF file and that never returned any error. Any idea what can be the cause for this?

Joshua Taylor
  • 84,998
  • 9
  • 154
  • 353
Som Sarkar
  • 289
  • 1
  • 5
  • 24
  • 1
    It would be useful to run something like `sed -n '15858p' SEALTriples.nt | hexdump -C` and post the output here... to make sure that the line is really OK. – Jakub Kotowski Feb 13 '14 at 17:00
  • 2
    I've noticed in a few of your posts now, we don't post the typical "Hello, …" and "Thanks…" in StackOverflow questions. It helps keep questions short and to the point. You get to thank people with upvotes and by accepting answers. :) I've edited the "kind regards…", as well as the "any help will be much appreciated". The politeness is nice, but it's unnecessary here; we know you'll appreciate help; otherwise you wouldn't have asked the question. :) – Joshua Taylor Feb 13 '14 at 17:25
  • Please include the line that's causing the problem. Just because another parser didn't complain doesn't mean that there's no error in the line, after all. – Joshua Taylor Feb 13 '14 at 17:26

2 Answers2

2

It is possible that file looks right on windows but isn't. N-triples files are UTF-8. If the text is actually Windows local code page it will look right when displayed (Windows native display) but isn't UTF-8.

AndyS
  • 16,345
  • 17
  • 21
1

I was able to find the problem. Actually there was a '\' in the object section which was creating the problem. Removing that made everything OK.

Som Sarkar
  • 289
  • 1
  • 5
  • 24