Hi Scott! I fully agree with what you are writing – we have seen the differences between text/something and application/something previously. My understanding is that json has to be application/json and that was probably the beginning of my struggle. Plan was to fully avoid translation in the Apache layer. Based on the recommendations I’m currently running with DefaulNetCCSID 1208 and DefaultFsCCSID 278, Will see if CgiConvMode %%MIXED/MIXED%% or %%EBCDIC/EBCDIC%% will show any differences. I’m reasonably new to Postman as well so I have many possibilities to make a mess….. Thank you very much for the advice and for providing YAJL. This is going to be fun! Best regards Stefan -- No trees were killed in the sending of this message, but a large number of electrons were terribly upset. Stefan Tageson +46 732 369934 From: ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx <ftpapi-bounces@xxxxxxxxxxxxxxxxxxxxxx> On Behalf Of Scott Klement Stefan, Personally, the setup I use is like this: DefaultFsCCSID 37 This tells Apache that my local system is CCSID 37 for EBCDIC (you might want 278 for Sweden, I don't remember) and that the network should be CCSID 1208 (UTF-8). This will cause Apache to translate the data from UTF-8 to EBCDIC when receiving, or from EBCDIC to UTF-8 when sending. If you leave off the DefaultNetCCSID, it will use CCSID 819, I believe -- and that's not Unicode, it's ASCII. The other thing I've noticed is that if you use 'text/xml' it will translate it, but 'application/xml' will not. It seems to differentiate between text documents vs. non-text -- and since XML is text, but has 'application' it causes problems. Same for 'application/json'. Therefore, you may need to read into a CCSID(*UTF8) field in your RPG program, and convert it yourself. Depending on the circumstances. If you are using YAJLINTO, consider telling it to read the input for you by specifying *STDIN as the document. DATA-INTO myDS %DATA('*STDIN') %PARSER('YAJLINTO') It has some sophisticated routines to properly figure out the encoding of the data and translate it properly so that it gets parsed correctly. If you want to call QtmhRdStin manually, you certainly can do that, but you'll have to figure out the encoding, too. -- Scott Klement sk@xxxxxxxxxxxxxxxx On 12/10/2020 4:08 PM, stefan@xxxxxxxxxx wrote:
|
-- _______________________________________________ Ftpapi mailing list Ftpapi@xxxxxxxxxxxxxxxxxxxxxx http://scottklement.com/mailman/listinfo/ftpapi