View previous topic :: View next topic
|
Author |
Message |
mkk157
Active User
Joined: 17 May 2006 Posts: 310
|
|
|
|
Dear Experts,
I use the SFTP to transfer the files from Mainframe to UNIX applicaiton.
My rquirement is to rename an existing file on OMVS with a new name on daily basis.
Is it possible ?
If so, please give me the sample code. |
|
Back to top |
|
|
Robert Sample
Global Moderator
Joined: 06 Jun 2008 Posts: 8697 Location: Dubuque, Iowa, USA
|
|
|
|
Is the file to be renamed on the remote server or the local machine? That will make a difference, as well. |
|
Back to top |
|
|
mkk157
Active User
Joined: 17 May 2006 Posts: 310
|
|
|
|
Hi Robert,
It is on my local machine (OMVS - Unix Partition of Mainframe Server) |
|
Back to top |
|
|
mkk157
Active User
Joined: 17 May 2006 Posts: 310
|
|
|
|
Hi Robert,
Any help on this ??? |
|
Back to top |
|
|
Robert Sample
Global Moderator
Joined: 06 Jun 2008 Posts: 8697 Location: Dubuque, Iowa, USA
|
|
|
|
Since the file is on the local machine, not the remote machine, using SFTP to do the rename will not work. SFTP rename is to rename a file on the server, not the client.
You can use the OMVS command mv to change the name of the Unix System Services file on the mainframe.
The syntax of the mv command can easily be found in the Unix System Services Command Reference manual or by using the man command in OMVS or via telnet session. I personally regard providing syntax of commands on a forum like this to be a waste of time -- my time since I already know where to find the syntax if I have questions, as well as the poster's time since if they are not willing to look up the syntax of the command in the manual then there's no motivation for them to learn anything on their own. With Google and IBM's various web sites, there's certainly no excuse for being unable to find command syntax. |
|
Back to top |
|
|
|