could somebody please verify that I’m not just too stupid.
My problem is that when I execute an XQuery with German umlauts (only tested with TStreamAccessor) those special characters are encoded twice.
For example: Just use a query with a simple constructor:
I see this problem is already known, because I found the following in the release notes for TAPI4J-4.2.1:
XML Documents: Encoding Information
The encoding information stored in the database currently gets lost. For TXMLObjectAccessor, this is because the underlying SAX parsers ignore the encoding information. For the TStreamAccessor implementation, this happens because no encoding information is recognized.
This is a very serious bug. Will there be a hotfix available soon?
Recently my team and I had that very same problem when sending xquery containing ISO8859-1 characters.
Guess what we found!!
This extremely experienced TAMINO team just hard-coded the encoding param!!
Deam… sorry for the sarcasm but this is really an issue I don’t do since college. Really a shame.
We had to decompile the API, modify this parameter and then recompile.
This was not a very elegant solutions, I know, but we hadn’t another choice…
At the moment I don’t have the details of the jar and the class recompiled but as soon as I get access to this code again, I promise I’ll post this solution.
Hi again, now I’ve got the solution we found.
I hope this to be helpful.
The class to modify is
which is under TaminoAPI4J.jar
there you’ll find a line that says:
set(“com.softwareag.tamino.db.api.io.Encoding”, new String(“utf-8”));
which should be changed for:
set(“com.softwareag.tamino.db.api.io.Encoding”, new String(“iso-8859-1”));
this encoding is for spanish, i don’t know if it is the same for german.
I attach the jar decompiled and modified.
Under this jar I left the source dor this class in case you need to modify the encoding param and recompile.
TaminoAPI4J.jar (463 KB)