Skip to content

CPYTOIMPF?

Post any question you may have in regards to GoAnywhere Director and let our talented support staff and other users assist you.
  • BillTW Offline
  • Verified User
  • Posts: 3
  • Joined: Tue Sep 15, 2009 3:29 pm

CPYTOIMPF?

Post by BillTW »

Support,

I am using the CPYTOIMPF command to build a text file that can be sent to a CC company. The CC company uses a Unix based system. They requested the file I send them be in a PC ASCII format. I am using FTP over SSH to send the file.

I am using the following command to build the text file.

CPYTOIMPF FROMFILE(ISDIDCFDV5/IDCA4DP) TOSTMF('/dirname/filename') MBROPT(*REPLACE) STMFCODPAG(*PCASCII) RCDDLM('*LF') DTAFMT(*FIXED) STRDLM(*NONE) STRESCCHR(*NONE) RMVBLANK(*NONE) FLDDLM(',')

I expect them to get a Hex character for line feed at the end of each record. They say they are getting 0D0A, which is incorrect. I don't think this is a Linoma issue but I thought I would ask. Could the software be inserting the extra end of line character?

Thank you,

Bill
  • Support_Duane Offline
  • Support Specialist
  • Posts: 66
  • Joined: Thu Mar 05, 2009 3:49 pm

Re: CPYTOIMPF?

Post by Support_Duane »

We can't really answer the question without seeing the files involved.

Please contact Support either by phone - (800)949-4696
or by e-mail - [email protected]
  • Support_Sai Offline

Re: CPYTOIMPF?

Post by Support_Sai »

The only thing that would convert LF (0A) to CRLF(0D0A) is if you are FTP'ing the file in ASCII format. The default transfer type under the FTP tasks is "auto", which sets the transfer type to ASCII or Binary based on the extension of the file. For example, if your TOSTMF file was named with an extension of ".txt", then the "auto" mode will choose ASCII transfer type. In order to prevent this from happening, edit the project, and change the transfer type to binary under the SFTP task -> Put sub-task. This ensures no data conversion no matter what and the file is sent as is to the remote server.

Hope this helps.
  • BillTW Offline
  • Verified User
  • Posts: 3
  • Joined: Tue Sep 15, 2009 3:29 pm

Re: CPYTOIMPF?

Post by BillTW »

Support_Sai wrote:The only thing that would convert LF (0A) to CRLF(0D0A) is if you are FTP'ing the file in ASCII format. The default transfer type under the FTP tasks is "auto", which sets the transfer type to ASCII or Binary based on the extension of the file. For example, if your TOSTMF file was named with an extension of ".txt", then the "auto" mode will choose ASCII transfer type. In order to prevent this from happening, edit the project, and change the transfer type to binary under the SFTP task -> Put sub-task. This ensures no data conversion no matter what and the file is sent as is to the remote server.

Hope this helps.
Sai,

That is good information. I checked the project and the Put sub-task is set to Binary mode. I will call support tomorrow.

Thank you,

Bill
Post Reply