× 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.



Jerry

I'll throw a couple things back at you -

1. A string of @@@ is usually the ASCII of the EBCDIC space - x'40' - there is some conversion going wrong there.

2. Instead of QDCXLATE, you might do well to use iconv() - this has a limit of 16meg, I think, and is the recommended way to convert text now - instead of the table-based QDCXLATE.

3. To know when you have all the data from a socket, aren't there basically 2 methods? Have a marker you wait for at the end, or put a count at the start and keep track? Sockets can get broken up in transit, so you can't guarantee how long each data segment is.

4. Maybe convert the text as you get it, then combine it. I also thought sockets did some conversion for you by itself - is this true? Saw a reference to sockets and their translation methods in the docs for QDCXLATE.

OK - am far over my head now!!
HTH
Vern

GKern@xxxxxxxxxxxxxxxx wrote:
I'm developing a new socket listener, based on Scott Klement's examples described in his article An Easier Way to Write TCP/IP Server Programs (using INETD).

Occasionally I'm sent large amounts of text (ie surgical pathology and/or DNA reports). Recently a hospital was trying to send me a report that was over 32k.

As time goes by I suspect these types of reports and the amount of data they include will become larger and more prevalent and I'm trying to prepare for that eventuality.
Is there any way to trap/detect if a data stream is larger than the what the socket's input field can handle? Can I extract a portion of the data? I ask that since I've been testing receiving data streams over 32k, but in debug the data appears as a string of @'s and I'm not sure what's causing that. I'm assuming it's 'error' related.
The numerous things I've tried (including searching the archives and the net) have left scratching my head as to how to proceed.
Also I know that QDCXLATE is limited to 32767 bytes. Are there any alternatives for translating text larger than 32k or should I just deconstruct and then reconstruct it in 32k chunks?

At the very least I'd like to be able to detect a large string, pull some identifiable data out of it and send off an email to the sender letting them know I can't handle data stream larger than x bytes long. Does that make sense?
Any suggestions/comments as to how I should attack this?

Thanks!

Regards, Jerry

Gerald Kern - MIS Project Leader
Lotus Notes/Domino Administrator
IBM Certified RPG IV Developer
The Toledo Clinic, Inc.
4235 Secor Road
Toledo, OH 43623-4299
Phone 419-479-5535
gkern@xxxxxxxxxxxxxxxx


This e-mail message, including any attachments, is for the sole use of the intended recipient(s) and may contain confidential and privileged information. Any unauthorized use, disclosure or distribution is prohibited. If you are not the intended recipient, please inform the sender by reply e-mail and destroy this and all copies of this message.

As an Amazon Associate we earn from qualifying purchases.

This thread ...

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.