Handling of empty file

Hi
my Scenario is Proxy to .CSV ,
when there is data  proxy is trggering and genarating the .csv file  this is working fine. but when i trigger  proxy without data it should create a empty file, but this empty file creating with special charecter.
FCC parameter i have used are
Record.fieldSeparator     ,
Record.endSeparator     <nl>
I would appreciate your timely help.
Regards
Chandra

Hi Chandra,
Instead of using File Content Conversion to convert the file structure, try using the standard module StrictXML2PlainBean instead. The problem is File Content Conversion doesn't identify an empty payload, even if you don't pass anything from the proxy. It doesn't return an empty message to the file adapter.
StrictXML2PlainBean or MessageTransformBean will do the trick for you.
Don't forget to set the empty message handling to Write Empty File.
http://help.sap.com/saphelp_nwpi711/helpdata/en/44/748d595dab6fb5e10000000a155369/frameset.htm
HTH,
Erwin

Similar Messages

  • Problem about Handling of Empty Files in File Adapter

    Hello everyone,
    NetWeaver 2004s --- XI
    In Sender i have a File Adapter.
    Now i meet a problem about Handling of Empty Files. When i send empty file, but don't cerate a leer message.
    I have seen following text in help document. But in adapter configuration i can not find the correspond parameter.
    can you give me some tips?
    Thx in advance
    best regards
    Yaning
    SAP Help Document über File Adapter
    +Handling of Empty Files
    Specify how empty files (length 0 bytes) are to be handled.
    &#9675;       Do Not Create Message
    No XI messages are created from empty files.
    The files are processed according to the selected Processing Mode.
    For example, if the processing mode is Delete, empty files are deleted in the source directory.
    &#9675;       Process Empty Files
    XI messages are created with an empty main payload.
    The files are processed according to the selected Processing Mode.
    &#9675;       Skip Empty Files
    No XI messages are created from empty files.
    Empty files are skipped and remain in the source directory.+
    Help Docu

    hi,
    it's available since Sp19 for XI 3.0
    and the corresponding SPS fpr XI 7.0
    http://help.sap.com/saphelp_nw04/helpdata/en/44/f565854b7341e6e10000000a1553f6/frameset.htm
    so probably you need to install the new SP
    Regards,
    michal
    <a href="/people/michal.krawczyk2/blog/2005/06/28/xipi-faq-frequently-asked-questions"><b>XI / PI FAQ - Frequently Asked Questions</b></a>

  • Problem with „Empty-File Handling" in PI 7.11

    Hi,
    Iu2019m working in PI 7.11 with file adapter, Sender CC, option: Empty-File Handling: Process Empty Files.
    What I want to do is giving target file the system-date, if the source file is empty.
    But I always get a mapping error in RTWB: Premature end of file.
    It seems that the payload is empty.
    Any idea?
    Thanks a lot in advance!
    Rene Dong
    Edited by: Rene Dong on Aug 31, 2010 4:20 PM

    What I want to do is giving target file the system-date, if the source file is empty.
    The error you are getting makes sense. You should do a check in the mapping, if the payload is empty then use brute force to pass the system date.

  • Empty File Handling in  SAP XI------Urgent

    Hi Frnds,
      1)  I have  one doubt XI will support Empty file processing. Suppose in my scenario
    In sender side i am having Empty file i want to process this file , what are necessary steps i need to take.
    2) In my scenario XI will support only 10mb file processing at a time, But in sender side i am having 20 mb file. How to transfer the file without splitting.

    hi raja
    Regarding empty file processing
    Handling of Empty Files
    Specify how empty files (length 0 bytes) are to be handled.
    &#9675;       Do Not Create Message
    No XI messages are created from empty files.
    The files are processed according to the selected processing mode.
    For example, if the processing mode is Delete, empty files are deleted in the source directory.
    &#9675;       Process Empty Files
    XI messages are created with an empty main payload.
    The files are processed according to the selected processing mode.
    &#9675;       Skip Empty Files
    No XI messages are created from empty files.
    Empty files are skipped and remain in the source directory.
    Also refer this link
    http://help.sap.com/saphelp_nw70/helpdata/EN/ae/d03341771b4c0de10000000a1550b0/frameset.htm
    This is done at ID in sender File Adapter Configuration of the communication.
    Regards
    Ramesh  P

  • Empty File handling and raise alert.

    Hi,
    We have requirement where we are doing file pass through. But client wants PI to raise alert when it receives 0 byte file.
    How can we achieve this using File/FTP/SFTP adapter when we are not reading the actual payload and doing only pass thru?
    Thanks,
    Vertika

    Hi Vertika,
    AFAIK - there is no standard way for pass through interface to raise alert (for empty file). so you need to develop adapter module to raise the alert for empty file.
    Please refer the help page
    Configuring the Sender File Adapter - Advanced Adapter Engine - SAP Library
    Under Handling of Empty Files, specify how empty files (length 0 bytes) are to be handled:
    Do Not Create Message No XI messages are created from empty files.The files are processed according to the selected processing mode.For example, if the processing mode is Delete, empty files are deleted in the source directory.
    Process Empty Files XI messages are created with an empty main payload.The files are processed according to the selected processing mode.
    Skip Empty Files No XI messages are created from empty files.Empty files are skipped and remain in the source directory.

  • How to Process an Empty File and deliver to the receiver channel

    Hello Gurus,
    We had a requirements to process an empty file and send it to the receiver channel .  We had successfully configured and polling an empty file, but the message output of the empty file was never sent to the receiver channel.  Is there any solution to process an empty file and move it to the receiver directory.
    XI 7.0 with latest sp
    Thanks so much in advanced,
    dn

    Thanks guys for a quick response!
    As mentioned above, we had already configured to handling "Process empty files" and were able to have the files polling successfully. The problem that we are facing is that, the output file were never created or delivered to the receiver directory. We want all files to process and deliver to the recipients even though it is an empty file.
    Thanks,
    David

  • Empty file pickup or not

    Hi all
    is it possible for pickup emty file , if it ok where is it configuration in file adapter?

    Hi,
    Handling of Empty Files:
    Specify how empty files (length 0 bytes) are to be handled.
    &#9675;      Do Not Create Message
    No XI messages are created from empty files.
    The files are processed according to the selected Processing Mode.
    For example, if the processing mode is Delete, empty files are deleted in the source directory.
    &#9675;       Process Empty Files
    XI messages are created with an empty main payload.
    The files are processed according to the selected Processing Mode.
    &#9675;       Skip Empty Files
    No XI messages are created from empty files.
    Empty files are skipped and remain in the source directory.
    But this option is not available in some service packs.
    I hope it is available in SP 19.
    Regards,
    radhika.

  • Empty files mapping problem

    I have to map empty files to another server. The first one is access by FTP.
    How can I do that?

    Hi,
    I didnt understand ur question can u pls explain in detail what r u looking for.
    in file adapter v have a option of handling empty file....
    refer the section Handling of Empty Files
    http://help.sap.com/saphelp_nw04/helpdata/en/e3/94007075cae04f930cc4c034e411e1/frameset.htm
    chirag

  • Why XI picks an Empty File ?

    Hi Gurus,
    I have a  case where i am getting a set of small files in a group to process in XI.As some time few files are comign with size ZERO bytes but the name is as per the XI standard.So XI picking the file for processing even if archiving in the archiving folder but i am unable to see those in SXMB_MONI and also alert configuration is unable to catch this .
    Can any one suggest how to solve this type of problem ?
    Thanks,
    Satya Jethy

    Raj,
    As described below from  help.sap.com
         Handling of Empty Files
    Specify how empty files (length 0 bytes) are to be handled.
    &#9675;       Do Not Create Message
    No XI messages are created from empty files.
    The files are processed according to the selected processing mode.
    For example, if the processing mode is Delete, empty files are deleted in the source directory.
    &#9675;       Process Empty Files
    XI messages are created with an empty main payload.
    The files are processed according to the selected processing mode.
    &#9675;       Skip Empty Files
    No XI messages are created from empty files.
    Empty files are skipped and remain in the source directory.
    I donot find these options available in Sender File Adapter. Do you know if this is available in PI 7.0 SP9 or am i missing something.
    Thanks
    Pradeep

  • Create a message with empty file in Service pack 9

    Hello.
    I have the Service pack 9, and when PI read an emtpy file delete it inmediately.
    Is there any way to create the message with an empty file? How?
    Thank you.

    Look into empty file handling in the file adapter. Below is from the sap help documentation for the file adapter.
    Sender File adapter
    Handling of Empty Files
    Specify how empty files (length 0 bytes) are to be handled.
    u25CB       Do Not Create Message
    No XI messages are created from empty files.
    The files are processed according to the selected Processing Mode.
    For example, if the processing mode is Delete, empty files are deleted in the source directory.
    u25CB       Process Empty Files
    XI messages are created with an empty main payload.
    The files are processed according to the selected Processing Mode.
    u25CB       Skip Empty Files
    No XI messages are created from empty files.
    Empty files are skipped and remain in the source directory.
    Receiver File adapter
    Select the Handling of Empty Messages:
    u25CB       Write Empty File
    An empty file (length 0 bytes) is put in the target directory.
    u25CB       Ignore
    No file is put in the target directory.

  • Receiver file adapter creates empty files, Empty-Message Handling SP19

    Hello,
    We have just upgraded the system to SP19.
    One of the new features is that it should be possible to determine how XI messages with an empty main payload are to be handled in the receiver file adapter.
    If the parameter Empty-Message Handling is set to 'Ignore' no file should be created if the main payload is empty. In our case an empty file (size 0 kb) is still created even though the main payload is empty and the flag is set to 'Ignore'.
    Has anybody experienced the same problem?
    //  Best regards  Hans

    This should work:
    Use your own adapter module that parses incoming message and checks if it has any record sets in the document. If it does not have any record sets, then set the message to empty and then give this modified message to File receiver.
    For example, see the example code below:
    Module imports..
    Audit log import..
    DOM imports/SAX imports..
    public ModuleData process(ModuleContext moduleContext, ModuleData inputModuleData) throws ModuleException {
              try {
                   // get the XI message from the environment
                   Message msg = (Message) inputModuleData.getPrincipalData();
                   AuditMessageKey amk = new AuditMessageKey(msg.getMessageId(),AuditDirection.INBOUND);
                   Audit.addAuditLogEntry(amk, AuditLogStatus.SUCCESS,"RemoveRootTag: Module called");
                   XMLPayload payLoad = msg.getDocument();
                   Document doc = parseXmlFile(payLoad.getInputStream());
                   if(doc != null){
                        if(!doc.getDocumentElement().hasChildNodes()){
                             Audit.addAuditLogEntry(amk, AuditLogStatus.SUCCESS, "Document is empty!!");
                             payLoad.setContent("".getBytes());
                             msg.setDocument(payLoad);
                   // provide the XI message for returning
                   inputModuleData.setPrincipalData(msg);
                   } catch (Exception e) {
                   // raise exception, when an error occurred
                   ModuleException me = new ModuleException(e);
                   throw me;
                   // return XI message
              return inputModuleData;
         private Document parseXmlFile(InputStream xmlpayload) {
              try {
                   DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
                   factory.setValidating(false);
                   //        Create the builder and parse the file
                   Document doc = factory.newDocumentBuilder().parse(xmlpayload);
                   return doc;
              } catch (SAXException e) {
              } catch (ParserConfigurationException e) {
              } catch(IOException e){
              return null;

  • Handling empty files Using SFTP adapter

    Hi folks,
    Can any please let me know how to handle empty file handling in SFTP adapter as a sender.
    I getting error in sxmb_moni while empty file coming in sftp adapter. Please help me on this issue.
    Thanks,
    Enivass

    Hi,
    please select option "Empty file Handling-*do not create Message*" in sender comm channel as per your requirement.
    Try this.
    Reg

  • Empty File Handling in xLink adapter

    Helloo Experts
    I am doing a scenario, which creates an empty file(when some mapping condition doesnt satisfy).
    I dont want to write this empty file in the target directory.
    This can be handled if a file adapter is used, but I am using a SOAP AXIS adapter, so I dont know how to handle this here.
    I alaso tried using the StrictXml2PlainBean to avoid the creation, it creates 0 documents and a 0kb empty file.
    Can anyone please let me know how this can be solved????
    Also if some one has done this empty file handling in J2SE file adapter...can you tell how it was done.
    Thanks a lot!!!!!!
    Regards
    Shobha

    Hi Gabriel,
                       You can write a simple script to copy a file from source folder to target in case the fiel size is ZERO bytes. The script will not copy the file if the filesize is more than zero bytes, This will be processed normally by PI server. You can call the script from sender communication channel parameter : "RUN OS command before message processing". Could you please specify the Operating System (OS) you are using in your PI server.
    Regards
    Anupam

  • ***Empty File handling,sender .txt file

    Hi All,
    Can we use the option Empty file Handle if the sender is a text file.
    if so how to achieve this.
    Thanks,
    Srinivasa

    Hi,
    Refer the section of 'Empty File Handling' from the below link:
    http://help.sap.com/saphelp_nw70/helpdata/en/e3/94007075cae04f930cc4c034e411e1/content.htm
    You will get the required result.
    Regards,
    Supriya.

  • Empty file handling in file?

    hi
    Q: how to handle empty file in sender/reciver file adapter?
    Thanks&Regards
    upendra kumar

    Upendra,
    You have an option in the communication channels. Just go through this help:
    http://help.sap.com/saphelp_nw04/helpdata/en/14/80243b4a66ae0ce10000000a11402f/frameset.htm
    ...Satish

Maybe you are looking for

  • My computer wont recognise my iphone when i plug it in.

    When i plu g my iphone into my computer it will, my windows 7 computer will no longer recognise it. I have tried diff ports and cable, then tried my laptop which it did work on, then tried a ipod touch on to this computer and it recognised that. I ha

  • Why is my network extender flashing red and pink?

    hi, I have had my Verizon extender for a while, I bought a new Motorola modem/router connected them up and now my network extender isn't blue like it was before. the system band is flashing red and the gps band is solid pink. I have unplugged it more

  • Function stats_mode on discoverer

    Good morning, Im using Oracle Discoverer 10.1.2.1, and I need use the group functions median and stats_mode available on Oracle Database 10g release 2. These 2 functions are not defined in Discoverer group functions. To use median function, I founded

  • Does not implement the NamespaceHandler interface

    I depoly a war file and get following errors. This project does not contain jar files related with spring. BUILD FAILED weblogic.Deployer$DeployerException: weblogic.deploy.api.tools.deployer.DeployerException: Task 0 failed: [Deployer:149026]deploy

  • Deactivate Adobe 5.5 Suite--but I don't have the computer anymore?

    I apparently need to deactivate the software that was on my previous computer before I can reinstall it on my new one, but the problem is: my computer crashed and is no longer available. So how do I deactivate the software when I don't have the compu