IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Commands in FTP


IBM Mainframe Forums -> All Other Mainframe Topics
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
khadar78
Warnings : 1

New User


Joined: 29 Apr 2008
Posts: 16
Location: Mysore

PostPosted: Thu Dec 31, 2009 3:54 pm
Reply with quote

Hi,

I have a requirement to fetch a file details from the server.
The suggestions came up were:
To get the file size or check the content of the file and read the data from the file..

Could anyone tell me. if there are commands in FTP for the above requirement??
Back to top
View user's profile Send private message
superk

Global Moderator


Joined: 26 Apr 2004
Posts: 4652
Location: Raleigh, NC, USA

PostPosted: Thu Dec 31, 2009 4:03 pm
Reply with quote

Use FTP to connect and logon to the server. Enter HELP to get a list of the FTP commands supported on that server. Then you can can use HELP <command> to further describe each command.
Back to top
View user's profile Send private message
khadar78
Warnings : 1

New User


Joined: 29 Apr 2008
Posts: 16
Location: Mysore

PostPosted: Tue Jan 05, 2010 10:40 am
Reply with quote

I tried searchin commands, but found with LS
LS = listing of contents in the current directory.

But i want to check if file 'X' is present in a directory.
If present find the content of that file.
After LS command it list downs all the files in spool.

Please let me know if anyone has inputs..
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8696
Location: Dubuque, Iowa, USA

PostPosted: Tue Jan 05, 2010 5:00 pm
Reply with quote

There are no FTP commands to do what you want -- FTP is not a scripting language, it is very specific to file transfers. However, you could connect to the server, issue an LS (or DIR) command to get the list of files, and then the next step could parse the file list looking for the particular file and its size; the third step could then be another FTP customized by the results of the second step to download the file. You will have to either use ISPF browse or edit to find the content of the file, after it has been transferred.
Back to top
View user's profile Send private message
khadar78
Warnings : 1

New User


Joined: 29 Apr 2008
Posts: 16
Location: Mysore

PostPosted: Wed Jan 06, 2010 2:13 pm
Reply with quote

Thanks Robert for your valuable response.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> All Other Mainframe Topics

 


Similar Topics
Topic Forum Replies
No new posts Console Commands All Other Mainframe Topics 4
No new posts commands missing in JESMSGLG JCL & VSAM 3
No new posts ZOS Console commands through USS REXX? CLIST & REXX 5
No new posts How can I know what tso commands are ... TSO/ISPF 18
No new posts ISPF Panel commands DDLIST /LISTBOX TSO/ISPF 11
Search our Forums:

Back to Top