IFSIO OPEN

Discussions relating to writing software in ILE RPG (RPG IV). This includes both fixed and free format RPG.
Post Reply
fanmechanic
Posts: 4
Joined: Thu May 11, 2023 3:56 pm

IFSIO OPEN

Post by fanmechanic »

Not sure if this is the right place, but since the IFSIO_H member is in FTPAPI....

We process inbound files from the IFS and it has been fine for years. A few days ago we upgraded from 7.2 to 7.4 and suddenly we can't open files for read. The process to open new files to write and send is Ok. debugging shows the generic -1 value for the file descriptor.

FD = OPEN(%TRIM(FILE) :O_RDONLY+O_TEXTDATA);

Any ideas to point me in the right direction are greatly appreciated.
fanmechanic
Posts: 4
Joined: Thu May 11, 2023 3:56 pm

Re: IFSIO OPEN

Post by fanmechanic »

i was able to retrieve the errmsg ad got "identifier does not exist". more research
fanmechanic
Posts: 4
Joined: Thu May 11, 2023 3:56 pm

Re: IFSIO OPEN

Post by fanmechanic »

correction, mistyped checking the error. real message is "conversion error"
fanmechanic
Posts: 4
Joined: Thu May 11, 2023 3:56 pm

Re: IFSIO OPEN

Post by fanmechanic »

for some reason since the OS upgrade the files are now CCSID 1208, not 819 like they were before.
Scott Klement
Site Admin
Posts: 719
Joined: Sun Jul 04, 2021 5:12 am

Re: IFSIO OPEN

Post by Scott Klement »

Moving thread to general RPG forum...
Scott Klement
Site Admin
Posts: 719
Joined: Sun Jul 04, 2021 5:12 am

Re: IFSIO OPEN

Post by Scott Klement »

In order to read UTF-8 files, you need to enable CCSID support.

Code: Select all

fd = open(%TRIM(FILE) :O_RDONLY+O_TEXTDATA+O_CCSID: 0: 0); 
Post Reply