ibmi-brunch-learn

Announcement

Collapse
No announcement yet.

Rename an IFS file in remote location

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Rename an IFS file in remote location

    Hi folks,

    I have a csv file in my IFS directory (on machine 1) and it?s being FTP to another machine
    (Machine 2). My problem is I need to rename the csv file (on machine 2) after the FTP process.
    Could anyone give me an idea or code sample for how to rename an IFS file in remote location would really appreciate.

    Ex:-

    On Machine 1

    Ifs Path: /Root/Dir1/
    File Name: MyfileA.csv

    then it will transfer over to Machine 2 using separate FTP process and there is no way to change the file name before that.

    On Machine 2

    Ifs Path: /Root/Dir2/
    File Name: MyfileA.csv


    Now I need to change the file name to (MyfileB.csv) form Machine 1


    If any input would appreciate.
    Cheers,
    Sudesh

  • #2
    Re: Rename an IFS file in remote location

    hi,
    not sure this is help or not:
    what do u means "Now I need to change the file name to (MyfileB.csv) form Machine 1
    "


    Comment


    • #3
      Re: Rename an IFS file in remote location

      Ok.. I figure out how to rename a file in ifs directory.
      Now my requirement is run a command remotely.

      We have 2 As400 machines (i-series machines) which connected to the same network.
      I need to run a command from my Machine 1 in Machine 2.


      Thanks in advance

      Comment


      • #4
        Re: Rename an IFS file in remote location

        ok this is u hpe

        Comment


        • #5
          Re: Rename an IFS file in remote location

          Hi Dhanuxp,

          Thank you for the input.
          However I can not use general FTP command as I should use organizational specific customized command for that.
          Anyway, now my problem is run a remote command from one As400 machine to another As400.

          (Just wondering about which company u working for in SL as my origin there)

          Cheers,
          sudesh

          Comment


          • #6
            Re: Rename an IFS file in remote location

            Originally posted by sudesh View Post

            Anyway, now my problem is run a remote command from one As400 machine to another As400.
            for what type of purpose!!

            there are some third party utility's if there have native-400 solution, tonite others will responce to u

            if u want to execute some ftp process ! just read attched - pdf

            dhanuxp
            Last edited by dhanuxp; June 23, 2009, 05:38 AM.

            Comment


            • #7
              Re: Rename an IFS file in remote location

              Ok, this is the command but i didnt try bcos of Permission issues,

              Code:
               RUNRMTCMD
              & this artical cover about runrmtcmd >>



              dhanuxp

              Comment


              • #8
                Re: Rename an IFS file in remote location

                Transfer data between two as400 systems without FTP

                Comment


                • #9
                  Re: Rename an IFS file in remote location

                  Hi folks,

                  Thank you everyone for all inputs.
                  Now I?m after RUNRMTCMD and I think I would be the best solution for my one.
                  I couldn?t run that and it felt over by saying
                  ?A remote host refused an attempted connect operation. ?
                  ?Command did not complete successfully.?

                  However I think I have necessary authority and access to the remote machine as I can run the intended command on remote machine manually.

                  Any comment would appreciate

                  Comment

                  Working...
                  X