View previous topic :: View next topic
|
Author |
Message |
main_ani_frame
New User
Joined: 10 Aug 2007 Posts: 6 Location: Kolkata, India
|
|
|
|
In my project, I am required to transfer an ASCII coded file from mainframe to desktop. I could do it using the 6 option (TSO or CLIST command). However when I tried to do the same using DOS shell, I could not. Could you please tell me how to do it using DOS shell?
I have another question in this regard. In order to transfer a file from mainframe to your desktop you write something like.....
IND$FILE GET 'ABC.OUTPUT' ASCII CRLF
Can someone please expand CRLF for me? I am just inquisitive about it.
Thanks!
Animall |
|
Back to top |
|
|
stodolas
Active Member
Joined: 13 Jun 2007 Posts: 632 Location: Wisconsin
|
|
|
|
So when you FTP from the mainframe to a remote server using option 6 it is ok, but when you try to FTP from a PC to a remote server and try to put it doesn't work?
What are you FTP commands in both cases? |
|
Back to top |
|
|
Craq Giegerich
Senior Member
Joined: 19 May 2007 Posts: 1512 Location: Virginia, USA
|
|
|
|
main_ani_frame wrote: |
Hi all,
In my project, I am required to FTP an ASCII coded file from mainframe to desktop. I could do it using the 6 option (TSO or CLIST command). However when I tried to do the same using DOS shell, I could not. Could you please tell me how to do it using DOS shell?
I have another question in this regard. In order to FTP a file from mainframe to your desktop you write something like.....
IND$FILE GET 'ABC.OUTPUT' ASCII CRLF
Can someone please expand CRLF for me? I am just inquisitive about it.
Thanks!
Animall |
IND$FILE is not FTP it is a file transfer program that is used with your terminal emulator. The ASCII CRLF indicates translate from EBCDIC to ASCII and add CRLF at the end of each record. FTP runs independent of your tso session. For DOS you would use something like:
Code: |
FTP
OPEN you host name or IP address
USER userid
PASSWORD *******
GET 'ABC.OUTPUT' abc.txt
QUIT
|
|
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
CRLF is Carriage Return/Line Feed. The CR moves the print position to pos 1 (left side), the line feed moves the "paper" down 1 line.
I suspect that you do not have a mainframe ASCII file. It is most likely EBCDIC text that will automatically be converted to ASCII during the FTP.
If you post the error(s) from your attempt at a command line FTP, someone will be able to explain what has happened. |
|
Back to top |
|
|
main_ani_frame
New User
Joined: 10 Aug 2007 Posts: 6 Location: Kolkata, India
|
|
|
|
Hi Stodolas, Craq and Dick,
The thing is that when I ftp ed the file using option 6, I clicked on the Receive files from host tool in the options tab, in the MVS/TSO tab I chose transfer type as text and in the Transfer option (file option) I checked out ASCII as it is meaningless to convert an ASCII file into ASCII format. That worked fine. But when I tried to go to Command Line and type ftp and then key in my PC s IP address and then type get <filename>, it did not work......
Thanks for your replies.
Animall. |
|
Back to top |
|
|
stodolas
Active Member
Joined: 13 Jun 2007 Posts: 632 Location: Wisconsin
|
|
|
|
If you are connecting to your pc and typing GET <filename>, the file better live on your PC and it will be transferred to the mainframe. Otherwise, if it lives on the mainframe, and you are opening your FTP session from there to an FTP server on your pc you need to use a PUT <filename> instead. |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello,
Quote: |
it did not work...... |
This is not the type of reply that will get you any help. . . You need to post what happened and any diagnostic info that was given. There are too many ways for something to "not work".
If you are on the desktop and want to "pull" a file from the mainframe, you may need to tell ftp that to download in ascii mode. Some software assumes binary and some uses "auto" that often fails. Once you are signed on to the mainframe ftp server, type ascii and press enter. You should get a response from the ftp server that the transfer type is now ascii. It won't hurt anything if it is already ascii.
If this does not fix your problem or at least change the symptoms, post all the info you have and we will continue. If you have success, please let us know. What you learn may help another sometime. |
|
Back to top |
|
|
|