× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Fighting with all kinds of new things...

** CURL in Ubuntu: This works.
curl -v -G --trace-ascii log.txt --data-urlencode 'XML=<AddressValidateRequest USERID="xxxxxxxx"><Address ID="0"><Address1></Address1><Address2>6406 Ivy Lane</Address2><City>Greenbelt</City><State>MD</State><Zip5></Zip5><Zip4></Zip4></Address></AddressValidateRequest>' http://production.shippingapis.com/ShippingApi.dll?API=Verify

(It is really ugly as one long string, but I don't know how to break it to separate lines. Tried \, but urlencode kept them. Don't know how the line will look when posted.)

** CURL in QP2TERM on Pub400.com: Works, using the above command.

** QSYS2.HTTP_GET on PUB400.com: FAILS (using the same big ugly string.)

values QSYS2.HTTP_GET('http://production.shippingapis.com/ShippingAPI.dll'
concat '?API=Verify&' concat
url_encode(
'XML=<AddressValidateRequest USERID="xxxxxxxx"><Address ID="0"><Address1></Address1><Address2>6406 Ivy Lane</Address2><City>Greenbelt</City><State>MD</State><Zip5></Zip5><Zip4></Zip4></Address></AddressValidateRequest>'
),
'{
"header":"Content-Type,text/xml",
"header":"Accept,*",
"header":"Content type,charset=UTF-8"
}'
)
;

Error: 80040B18, An error has occurred with the service. Please contact the system administrator, or try again.

** Could it be a CCSID issue? Pub400.com is German, CCSID(273) but i'm running in the USA which I believe means Run SQL Scripts is running in CCSID(37). I tried CL: CHGJOB CCSID(037) first but it made no difference, though the QZDASOINIT job did change. Don't see a way to change the JDBC ccsid. Is url_encode ccsid sensitive?

I tried this to verify url_encode looked good and it seems to work fine.
values url_decode(url_encode(
'XML=<AddressValidateRequest USERID="xxxxxxxx"><Address ID="0"><Address1></Address1><Address2>6406 Ivy Lane</Address2><City>Greenbelt</City><State>MD</State><Zip5></Zip5><Zip4></Zip4></Address></AddressValidateRequest>'
));

On 1/4/2022 10:39 AM, Jack Woehr via MIDRANGE-L wrote:
You're welcome, and keep us ... um ... "posted" on what you find out.
I'm sure many of us at one time or another will have to do EDI with USPS!



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.