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



Hi Everyone,

I have a general purpose utility program (CPYTOCSV) that uses a program-described file for its input and writes to the IFS. Up until today, no one had used it to copy a file that contained null-capable fields. My first thought was, just put ALWNULL(*INPUTONLY) on the H-spec and recompile. No such luck.

I did a little reading of the v5r3 RPGLE manual and found these two notes:

* An input operation from a program-described file using a data structure in the result field does not affect the null indicator associated with the data structure or any of its subfields.

* Reading null-capable fields using input specifications for program-described files always sets off the associated null indicators.

I think the assumption for these two statements is that the input specs for the program-described file match the externally-defined fields. In my case, I have a single 32k field. And it gets a data-mapping error when it reads a record with a null field. Not just null-capable, but actually null.

Is there a way around this?

tia,

*Peter Dow* /
Dow Software Services, Inc.
909 793-9050
pdow@xxxxxxxxxxxxxxx <mailto:pdow@xxxxxxxxxxxxxxx> /

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

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.