OS Command for receiver file adapter

Hi Guys,
I have a requirement that in the target folder before putting the file, I have to rename the exisitng file then put the file. The target folder is in another machine and I have to use FTP option to send file.
is it possible to use OS command after processing option in the receiver file adapter to do this? please let me know how to handle this.
Thanks
Mukesh

Mukesh,
You cannot rename the file in the FTP folder. What you can do is write a OS script where it logs in into the FTP site and renames the file. Then use this OS script before message processing so that it renames the file before you write the actual file.
If you want to rename a file which is on the applicaiton server using NFS then you can directly rename it from the command prompt.
Regards,
---Satish

Similar Messages

  • Dynamic  File Name for Receiver File Adapter

    Hi All,
    How can we use dynamic name for Receiver file adapter?
    Can anyone help.
    Thanks in Advance
    Chemmanz

    Hi Chemmanz,
    The dynamic filename generation concept is as follows.
    In your filename field. just give a variable with % symbols. (eg: %file% ).
    Now, under the option Variable Name Substitution, you can give how the value has to be created.
    It can be your interface name, sender service name, etc or it can be some value dynamically from your payload.
    For the former, your give
    message:interface_name ,etc
    and for the payload part you give,
    Payload: "your element root which u wanna acecss"
    Just check this link out,
    http://help.sap.com/saphelp_nw04/helpdata/en/bc/bb79d6061007419a081e58cbeaaf28/content.htm
    And read the contents under variable substitution and it will help you understand the concepts better.
    If you have any clarifications, do get back,
    Regards,
    Bhavesh

  • Attachments for receiver file adapter

    Hello gurus,
    I think receiver file adapter does not support attachments. But I do have a scenario where I receive additional files as SOAP payloads accompanying  the request message and I have to write them to a network directory. How can I achieve this?
    Regards,
    Gökhan

    Hi Gokhan,
    Please have a look at the following links and see if it helps
    Re: File adapter with attachment to mail
    Re: How to use File Adapter to transport files
    Best Regards

  • Variable Substitution settings for Receiver File Adapter

    Hi All,
    I wanna use variables for File Name Sheme in the File Access Parameters.I had used by enclosing the variable names within %. When i wanna substitute values for those variables, it is given in the documentation(help.sap.com) that v need to set the Enable indicator. only after setting the indiactor, v can use the variables and can then enter the values for those variables in a table. but i can't see either the indicator or the table in my editor. how can i provide the values for the variables used in file name scheme/Target Directory. and for ur information,i'm using sp12.
    any help wud b appreciated.
    thnx
    Anil

    Hi Anil,
    Please check out the following link ...
    Re: Variable substitution - Pseudo Path Variable - file adapter
    Re: Variable substitution problem
    Regards,
    Raj

  • XML Format not poper For receiver File Adapter

    I am using XML File to xML File scenario. My receiver is SAP R/3 system. When I send file from another system, It is properly seen in payload but the file is not properly recived on SAP R/3. The XML File appears on single line and when seen on SAP side side the fileis cut after some length. Any help is appreciated.

    hi,
    >>>The XML File appears on single line and when seen on SAP side side the fileis cut after some length. Any help is appreciated.
    it's probably not the XML file file that is corrupter but the way you view the file
    do you open it from AL11? if so it does not show the whole file
    PI/XI does not cut XML files for sure
    Regards,
    Michal Krawczyk

  • REG: Acknowledgement for receiver file adapter

    Hi All,
               I have a scenario where i need to make a rfc call  to update SAP table after the file is placed in the target folder. Can this be acheived without using BPM.
    Thanks,
    Siva

    Hi Siva,
    I think this cannot be achieved without BPM. You need to go ahead with BPM.
    /people/michal.krawczyk2/blog/2006/06/22/xi-playing-with-the-file-adapters-acknowledgments
    http://www.sap-xi.com/sap-xi-scenario-rfc-file.html
    Thanks,

  • Error dynamic File Name in Receiver File Adapter

    Hi all,
    Dynamic file name for Receiver file Adapter Problem
    my multi mapping look like this in design mode
    messages
         message1
              SD01_E
                   FileName
                   row
         message2
              SD02_E
                   FileName
                   row
    by processing the xml look like this:
    <ns2:SD01_E xmlns:ns2="urn:lsv.de/SAP/XXX">
    <FileName>L40SA939.xiConstant</FileName>
    - <row>
    or
    <ns2:SD02_E xmlns:ns2="urn:lsv.de/SAP/XXX">
    <FileName>L40SA939.xiConstant</FileName>
    - <row>
    in file receivere adapter  i have try this but it dos not work
    payload:SD01_E,1,FileName,1
    Error:com.sap.engine.lib.xml.parser.ParserException: XMLParser: No data allowed here: (hex) 0(:main:, row:1, col:0)
    is there any way to have access to Filename  in different root elements??
    regards
    Ralf

    Hi Ralf,
    i think, you need for each XML msg (each different root element) a new adapter -> a new IF determination, new rec agreement and a new channel.
    Regards,
    Udo

  • Receiver File adapter content conversion using StrictXml2PlainBean

    Hi All,
    For receiver file adapter i am using the module StrictXml2PlainBean, and also i mentioned the module configuration like this
    parameter name                              parameter value
    recordTypes                                  Header,TransactionHeader,TransactionDetail,TransactionTrailer,FileTrailer
    FileTrailer.endSeparator                |\n
    FileTrailer.fieldSeparator               |
    Header.endSeparator                   |\n
    Header.fieldSeparator                  |
    TransactionDetail.endSeparator   |\n
    TransactionDetail.fieldSeparator  |
    TransactionHeader.endSeparator |\n
    TransactionHeader.fieldSeparator |
    TransactionTrailer.endSeparator  |\n
    TransactionTrailer.fieldSeparator |
    But when i send the idoc, The receiver CC is throwing an error
    Message processing failed. Cause: com.sap.aii.af.modules.conversion.xml2plain.ConversionException: Invalid structure name encountered during conversion: Transaction at XML element MT_DeliveryOrder,Transaction
    My actual structure is
    MT_DelvOrder
       Header  0...1
       Transaction 0....Unbounded
          TransactionHeader  1..1
           TransactionDetail     0...unbounded
            TransactionTrailer  1...1
       FileTrailer  0...1
    The module is checking for the Transaction node,but i require the rest 3.
    Same configuration i have done successfully with FCC without using the module....
    So can any one suggest me where i am missing... why the module is pointint towards, the Transaction cant i ignore this node . and continue with the rest???
    Regards,
    Sridhar
    Edited by: sridhar reddy kondam on Aug 10, 2009 12:35 AM

    Hi Rajesh,
    The same FCC configuration was working fine with FCC and when i am using this module configuration i am getting the prob...
    In the file i need the Header,TransactionHeader,TransactionDetail,TransactionTail,Filetrailer
    my sample output file is
    <?xml version="1.0" encoding="UTF-8"?>
    <ns0:MT_DeliveryOrder>
    <Header>
    </Header>0...1
    <Transaction>0...Unbounded
        <TransactionHeader> 1..1
         </TransactionHeader>
         <TransactionDetail> 0...Unbounded
         </TransactionDetail>
          <TransactionTrailer>1...1
           </TransactionTrailer>
    </Transaction>
    <FileTrailer> 0...1
    </FileTrailer>
    Any suggestions will be great help...
    I think i need to go with other options without using this module....
    Regards,
    Sridhar
    Edited by: sridhar reddy kondam on Aug 10, 2009 6:03 AM

  • Receiver File Adapter with File content Conversion

    I have a requirement to send 2 different files to the target directory. Source is the same and different mapping for the 2 files.
    This I can achieve through multi-mapping but there is a problem. How can I use the File content for receiver File adapter which is using Multimapping.
    The structure of the 2 files also different.

    Why would you need FCC on receiver file adapter? If you need different files to be generated from the source, you could create two receiver channels with different mappings and just add them to the same Receiver Detemination. Isn't feasible?

  • Encoding issue in receiver file adapter

    Hi experts,
    I am having a file to file scenario using integrated configuration where i am using file encoding 'US-ASCII' for converting the target file to ASCII and its not working.
    Is there any other settings need to be done in the receiver file adapter to convert to 'ASCII' encoding format?
    Do we have any other method to convert to 'ASCII' format for the receiver file?
    .txt file is used for this interface.
    Thanks!

    Hi Mahakrishnan,
    What is the format of file mentioned in sender file adapter? If SAP-PI is receiving File format in US-ASCII. Then mention US-ASCII in sender communication channel in file encoding field,file type will be text. In case the file format  received by SAP-PI is normal text file then by default sender adapter will convert it to UTF-8. Maintain the  file type=text and encoding=US-ASCII for receiver file adapter also.
    ASCII is an alias for US-ASCII file encoding, hence both mean the same encoding. Thus this format should work. If its still not working please refer to SAP note 821267.
    Regards
    Anupam
    Edited by: anupamsap on Mar 9, 2012 5:47 AM

  • Scheduling Receiver File Adapter

    Hi All,
        I would like to know if "Planning Availability Times" works for receiver file adapter (communication channel).
    My scenario is IDoc to file. The IDoc from SAP end might be sent to XI at anytime but XI has to create the target file at a specific time on a day (say 9 pm). I'm just wondering if I can use "Planning Availability Times" to schedule the receiver cc.
    Thanks in advance.
    Regards,
    Joe.

    Hi,
    Reffer these
    Polling based upon availability
    http://help.sap.com/saphelp_nw04/helpdata/en/45/06bd029da31122e10000000a11466f/frameset.htm
    /people/shabarish.vijayakumar/blog/2006/11/26/adapter-scheduling--hail-sp-19-
    Regards
    Seshagiri

  • Receiver File Adapter Not Executing OS Command

    Hello All!
    We are currently running PI 7.1 and wish to use a Receiver File Adapter to FTP a file to a mainframe and override the FTP system defaults.
    Tried using the 'quote site recfm=fb lrecl=80' OS command but discovered that this would not work as the Adapter Engine is NOT on the mainframe.
    Regrouped a bit and made a second attempt which involved writing a Unix script to ftp a file and override rthe system defaults.   The idea was to use the File Adapter to FTP the data to the server, invoke the script and get the file to the mainframe with the proper attributes.    The script when executed on the server works perfectly.   
    However, when the IDoc comes thru PI, the File Adapter ftp's the file ok but the script is never executed.
    Any ideas why this is so or any suggestions?    
    Thank you.

    Hi Ken,
    Script only executes at Network File sharing (NFS) only. It dont work at FTP level.
    So you can better write the file on NFS and then within the script to connect to ftp and do your processing.
    Regards,
    ---Satish

  • Receiver file adapter command line

    hi,
    i am just wondering how to use command line on receiver file adapter.
    i am not clear how to use this.
    please modify on the following command!
    anyway, i have to call java application after put some files by receiver file adapter.
    cmd.exe %Fjava ./javacalltest
    it did not work..
    please guide me.
    Command Line
    An operating system command specified here is executed before or after a file has been successfully processed. The default value is an empty character string (no command).
    When the operating system command is called, the file name currently being processed can be specified with the following placeholders:
    %f (file name)
    %F (absolute file name including path)

    Hi Ogawa and Laurence,
    Have look at :: /people/michal.krawczyk2/blog/2007/02/08/xipi-command-line-sample-functions
    1)Windows batch Commands::
    http://labmice.techtarget.com/articles/batchcmds.htm
    2)Linux:
    /people/michal.krawczyk2/blog/2005/08/17/xi-operation-system-command--error-catching
    Note:: First try using the comands on O.S if they work then only use them in Adapters.
    Hope it will help.
    regards
    Piyush
    Pl:reward some points if it is usefull.

  • Receiver file adapter error for special char.

    I am using MTB in my receiver file adapter. I am getting a special character from source system at end of the string. How to resolve this type of error u2013 please advice.
    This error is not coming for every message.
    Error message:
    Column value xxxx   too long - must stop, probably configuration error in file adapter
    Thanks
    Vick

    Hi,
    Itu2019s basically IDOC to file scenario.
    This error is coming for name field.
    What I am thinking at this stage to do changes in MTB by define parameters like (NameA.enclosureConversion)

  • Configuring Receiver File Adapter for J2SE

    Hi All,
    I have a scenario in which i need to convert the IDOC data into a fixed length file.
    I did mapping according to the output structure of the file.
    My Output file format is as follows...
    Document1          document2      document3      etc
    Each document contains different fields with different lengths
    In XI-FIle adapter we give Recordset structure : Document1,Document2,Document3.
    But while configuring Receiver File adapter in J2SE.
    There is no option mentioned in J2SE Adapter.
    <b>http://saphelp.border-states.com/EN/95/bb623c6369f454e10000000a114084/content.htm</b>
    Please throw some light on the same.
    Thank You
    Regards,
    Reehan

    as far as i read the document, what i understood is that the J2SE adapter has a limitation.
    your XML structure should be as mention in the link;
    <i>To convert a table in XML format to pure text format, the document format must be the same as that which is generated by the sender file/FTP adapter in mode FILE2XMBWITHROWCONVERSION <i>(with the default value <row> for the structure)</i> and the sender JDBC adapter. This means that the document structure looks like this:
    <resultset>
    <row>
    <column-name1>column-value</column-name1>
    <column-name2>column-value</column-name2>
    <column-name3>column-value</column-name3>
    </row>
    <row>
    <column-name1>column-value</column-name1>
    <column-name2>column-value</column-name2>
    <column-name3>column-value</column-name3>
    </row>
    </resultset>
    This is an example for 3 columns and 2 lines. The number of lines and columns is, of course, unlimited. <b>The XML elements in italics can be defined by the user and the elements of a line must be grouped within an element of type <row> … </row></b>.</i>
    So cannot take the <b>recordset structure</b> as we have for the normal File adapter.

Maybe you are looking for

  • Pdf files websites does not open

    Hi, I can open most links with .pdf extension on any other browsers like Google Chrome and IE9 but not with Firefox 4. Actually I don't think I was able to open these type of files even with Firefox 3.6. When I click on a link with a .pdf it would ju

  • How to convert workflow template number into transation code?

    Hi Experts, We are using WS20000081 Leave request workflow in SAP 4.7.I created one customized workflow according to the client requirement.How can i convert WS99900009 into Transaction? I created one absence type with workflow template WS99900009.Wh

  • Zen touch isnt working at all *NEED HELP

    Today, i went to unplug my zen touch from charging to download some songs to it. Once i got it to my computer i noticed the power light was on, but the screen was blank, no picture, light, no anything. This player is only about a month old(i got it f

  • BADI for modifying PO price based on Shipment Date

    Hi all, When we create an invoice for a purchase order or scheduling agreement, the price that is considered is, by default, the price on the GR (goods received) date. Now, the business requires that the price on the shipment date has to be considere

  • Cannot connect at home

    I am so frustrated, I have a new Apple TV, and an actiontec router and my Apple TV will not connect.  I took it to an apple store they set up my router and connected the Apple TV wirelessly to that and it worked flawlessly.  I got it home and it is n