× 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 Brad,

<snip>
I am still having problems with this.  I tried using
O_CCSID instead of O_CODEPAGE, but I'm still getting the "conversion error"
message from the open on the stream file.

But, here's my question.  If I compile with O_CCSID to
V4R5, but run it on V5R2, will this be a problem?  To use
the functionality with O_CCSID would I have to compile to
V5R1 or higher?
</snip>

That would depend on two things:

1) Has the procedure interface changed between releases? That is, have they
changed in a way that backward compatibility is not preserved? Adding an
optional parameter in a particular release shouldn't matter, as long as you
use the original "limited" prototype for your call. (Having said that, I
don't know if the OS supports something akin to signatures for the service
programs they provide for these APIs. If they do you may have a headache
there).
2) Is this service provided by a different service program in the different
releases? If the procedure resides in different service programs then you
may attempt to load the wrong service program in a release other than that
used during binding. 

Setting O_CCSID is simply switching on a particular bit in the 4-byte
integer passed as the open flag. Both versions of the API should still pass
an INT(4) as the open flag so nothing has changed there. I'd imagine you
"could" switch the bit on and compile it to V4R5 (assuming on a V5R2
machine).

The inclusion of the O_CCSID flag will not make a difference until run-time.
Only then will the API check to see if the flags are correct. As long as you
pass an INT(4) in your program the compiler/binder will be happy. However,
once you run the program at an OS version where O_CCSID is not supported you
will get an error.

So, on a V5R2 machine you could set O_CCSID, compile to V4R5, and it would
compile OK. It should run at V5R2 too. I would expect it to choke on an
earlier release, where O_CCSID is not supported (and you consequently
haven't set O_CODEPAGE either).  

Not sure if this addresses your question, and it could all be wrong. :-)

Cheers

Larry Ducie 



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.