Webservice and codepage - Forum - OpenEdge General - Progress Community

Webservice and codepage

This question is not answered


We have a webservice that receives an XML document in a longchar. If I remember correct you may use fix-codepage(lcVariable) = '.....' to set the codepage for the longchar. Since our db is iSO8859-1, I assume that the codepage will convert what it gets from the webservice into iso8859-1. 

What happens if the XML is UTF-8 or UTF-16? Since there is several systems sending info to the webservice, I assume that we could get several different types of XML documents with different encoding. How should we handle that?

It seems to work as it is, but now and then we get crapy characters, so I assume it has something to do with this. I know I could peek into the xml and get the encoding, but since I already have received the document into a longchar that probably already have done some convertion, I assume that the content of the longchar is corrupt. 

All Replies
  • And fix-codepage() can't be done, since it is filled before I get to do a fix-codepage() hence it is an input parameter.