File adapter/JDBC adapter processing

Hi,
I have scenarion as below
> XI gets an IDOC message from R/3
> Based on that message XI uses a fileadapter to call a UNIX shell script in the other system (system B - non SAP)for pre-processing.
> The script call returns no errors.. So, XI/BPM now uses the JDBC adapter to convert the IDOC into a JDBC insert.
> On successful inserts, the process again uses a file adapter to perform a post-processing script call
Is the above scnarion possible using JDBC/File adapters in XI/BPM ?
Thanks
mad

Hi Maddux,
Is it a pre-codintion to execute the unix shell script before inserting the data using JDBC adapter?
FYI, If there is no pre-condition and you want to send the data to two different systems, you can configure multiple receivers(both file and JDBC) in your Receiver Determination object without BPM.
-Sam Raju

Similar Messages

  • File Adapter , Processing Sequence

    Hi All,
       Can you please help me to understand these?
    1. When i configure a Sender File Adapter with file pattern *.txt, Does it handle the files one after another? Or does it span multiple threads and processes multiple files in parallel?
    2. If i select processing sequence as DATE, does it consider the time stamp also?
    3. If a 100 mb file with name BIG.txt created at 1.00 AM,
        and a 0.1 mb file with name small  created at 1.10 on the sender system. If 100MB file needs 30 min to get processed,
    Then can i assume the second file get processed only after big file completely processed and reached the destination?
    Regards
    Ganges Leaves

    Ganges,
    During any polling interval, XI will pick all files matching your Criteria and process them parallely.
    Even if the big file is being processed, the next file will be picked up by the adapter if it is available during the next polling interval.
    All interfaces are  executed independent of the other.
    All this is if u choose the mode as    <b>Best Effort</b>.
    Regards,
    bhavesh

  • File Adapter-Processing Parameters

    can one tell me the difference between and when to use the following processing parameters
    poll interval(secs)
    poll interval(msecs)
    Retry Interval(Secs)
    Advanced Mode & Msecs to wait before modification

    Hi,
    from help.sap.com
    http://help.sap.com/saphelp_nw04/helpdata/en/e3/94007075cae04f930cc4c034e411e1/content.htm
    <b>Poll Interval (secs)</b>
    Number of seconds that the adapter must wait if no files are found for processing.
    <b>Poll Interval (msecs)</b>
    Additional waiting time in milliseconds.
    If Poll Interval (secs) is set to null, processing times will be short and close to real time.
    If Poll Interval (secs) and Poll Interval (msecs) are set to null, the adapter is only called once.
    <b>Retry Interval (secs)</b>
    Specify the number of seconds that the adapter is to wait before a file processed with errors is processed again.
    If the value is set to null, then the adapter is canceled if an error occurs, even if a value greater than null is specified for Poll Interval (secs).
    Regards,
    michal

  • File adapter processing in FTP mode

    Hello SDN,
    I need some info on File adapter working in FTP mode.
    What happens when we point to a remote file location that runs on FTP server?
    FTP in standard does not support a remote read operation at all. So the only possible logic that strikes me is issue a FTP get command over the file and get the file locally, read it. Does it happen this way? Or SAP has customised FTP to enable the read operation from a remote location directly?
    Regards,
    Jai Shankar

    Hi Jai,
    I am sure you must have gone through this File/FTP help file earlier also. If you read the Procedure section of it, I think it will give you a clear idea what exactly happening there:
    http://help.sap.com/saphelp_nw04s/helpdata/en/0d/00453c91f37151e10000000a11402f/frameset.htm
    Regards,
    Subahsha

  • File Adapter--Processing parameter configuration

    Hi Experts,
    I need to configured the sender and reciever FTP Adapter to Archive a 37 MB text file within a FTP server.
    It is taking 20 min to archive the file.
    does this requirement requires any change in Parameter configuration(like transfer mode, channel availabilty planning( i am using daily with duration 30 min) to make it fast.
    Thank you,
    MK

    Hi Experts,
    To archive huge files using FTP adapter, i looked at the Michal weblog to zip the file :
    /people/michal.krawczyk2/blog/2007/02/08/xipi-command-line-sample-functions
    please explain how and where to write the below file
    @ECHO OFF
    7za.exe a -tzip D:\file_cat\%2.zip %1
    del %1
    and also explain
    Zipping a file can also be done with jar.
    For example,
    jar cvf m.zip m.txt
    will zip m.txt into m.zip
    No need for any other software as jar is highly likely to be on the XI/PI server...
    and how to implement it in the FTP  adapter configuration.
    Thanks in Advance.

  • File adapter causes FTP process stop result 0 byte file.

    Has anyone ever heard that FTP adapter can cause FTP process to stop and end up with 0 byte file transferred?
    We use the normal ftp script to ftp file from external file server place file in XI inbound folder so that file adapter can pick them up from that folder.
    We have encounter a few 0 byte FTPed file in our system. One suspecting is the network between XI server and file server might get some interruption. With out just blaming on the network. We would like to know if there is any possibility that it is also causes by our file adapter? Says, it try to read the file that is not yet complete transferring make FTP give up transferring??
    We would like to know if FTP process is transferring the file over and file adapter try to read, what will happen? Will it read file with incomplete content and ftp still go on? Or will it stop reading and return back error as the file could not be open? Or it will force FTP process to let go the file??
    Best rgds,
    Thida

    Hi,
    ><i>We would like to know if there is any possibility that it is also causes by our file adapter? Says, it try to read the file that is not yet complete transferring make FTP give up transferring??</i>
    have not seen the file adapter causing any such problems. So, it looks like a network issue.
    ><i>We would like to know if FTP process is transferring the file over and file adapter try to read, what will happen? Will it read file with incomplete content and ftp still go on? Or will it stop reading and return back error as the file could not be open? Or it will force FTP process to let go the file??</i>
    Am not exactly sure, but when a file is being created and the file adapter tries to read such a file, the file would be READ and WRITE Locked and so File adapter should not be able to read such a file until the creation of the file is complete.
    Also, take a look at the note :  <b>821267</b> , question 31 for how file adapter processes empty file.
    Regards,
    Bhavesh

  • Receiver File Adapter - Empty document found error

    Hi,
    I have a slight issue that I do not understand.
    For example, I have a file that is 256 bytes in size and definitely has some content. However, when the file adapter processes the file it says in the log "Empty document found" - but I can see the file has content.
    Any ideas ? I am using using XI 3.0 SP19.
    Cheers
    Colin.

    hi colin,
    i will agree with u,
    may be the XI can not understand your test data,
    can u tell me the language of test data.
    In file adapter go to encoding select TEXT and  UTF-8.
    may be this will works.
    regards
    sandeep.

  • File Adapter - anonymous login (or )User name ,password login - Efficient?

    Hi Folks,
    In File Adapter processing , anonymous login (or) proper user name password based login is recommended ?
    Because we have faced many issue while using username based login in File adapter  .
    Which one is best ?
    Regards.,
    Shiva

    Hi Shiva ,
    We will go one by one :
    You can go for the Anonymous login  but the problem is the any body can access the FTP server and it is not the secure one,that is why business generally don't allow the Anonymous login.
    Coming to Proper user name password login ,I would advice you to use this one as the connection is more secure in this case.But this also comes with a problem that the username password generally expires after some time as per security policy and you have to change the username password for the FTP server as well as in File adapter which you are using.But this problem can be solved by going for a permanent username and password.
    I would recommend you to go for Proper user name and password.
    Regards
    Ravi Anand
    Edited by: Ravi Anand@85 on Mar 12, 2010 7:56 AM

  • File adapter - Unexpected exception running file2xmbprocessor

    Hallo,
    I've a fileadapter running and a couple of time the adapter is running fine.
    After a while I get the following exception:
    <i>Unexpected exception running file2xmbprocessor
    java.util.NoSuchElementException
    at java.util.TreeMap$EntryIterator.nextEntry(TreeMap.java:1024)
    at java.util.TreeMap$KeyIterator.next(TreeMap.java:1051)
    at com.sap.aii.messaging.adapter.File2XMBProcessor.processFileAccess(ModuleFile2XMB.java:1383)
    at com.sap.aii.messaging.adapter.File2XMBProcessor.run(ModuleFile2XMB.java:872)
    at java.lang.Thread.run(Thread.java:534)
    File adapter processing stopped</i>
    I have no idea whats wrong.
    Any idea
    Thanks harald

    Hi Prasad,
    sorry - but I can't understand what you mean.
    The file-adapter I'm talking about runs on a fileserver. This adapter read the files and send them to the XI-System where a java-mapping is running.
    Therefore I can't believe that the problem is the mapping.
    The way I see it is that the error must be in a part of the file-read-process because the exception says
    <b><u>[fileprocessor]</u> Error: Unexpected exception running file2xmbprocessor
    java.util.NoSuchElementException
    at java.util.TreeMap$EntryIterator.nextEntry </b>
    Could you please explain what you mean.
    Thanks and best regards
    Harald

  • Generic File Adapter Schema

    I am trying to pick up a .csv file that doesn't comform to a strict format, mainly because of human formatting errors in the file.
    I've tried to create a fixed length schema and a comma delimited schema but both fail as soon as they get a file that doesn't exactly fit. How should I create the schema to cope with a file like this?
    Regards
    Jen

    I too am trying to accomplish something similar.
    My file is tab delimited and has 10 fields. It begins with 6 lines of header and ends with 1 line of footer. The Header is easy enough to skip over, but the footer is causing me no end of problems because the file Adapter is rejecting the entire file when it hits this malformed line. I tried to turn on uniqueMessageSeparator as ${eol} but that didn't seem to do anything different (I suspect it is because ${eol} is also a field terminator for the last field but I'm not sure).
    Ideally I'd like to say any line that has 9 tabs is a Data line, and any line that doesn't is a NotData line but I haven't found any functions that will take a regular expression match as a condition for processing in the XSD.
    I tried using the "choice" method of conditional processing but is seems that I must provice a string that is an exact match for nxsd:conditionValue and not a regex. I don't have a spcific string to look for.
    I also tried to use the "Sequence" method of conditional processing that will treat any record that doesn't begin with a digit as a NotData Message of 1 string element terminated by ${eol} and any record that begins with 8 digits (which is a date in YYYYMMDD format) as a Data record using the "nxsd:startsWith" function but it seems I can only create multiple message types on files when there is some specific string to test. That's not going to work for me. There is no specific string on the records to identify them. The format of the line could be used to identify the records if a function supporting a regex could be found.
    When I tried to deploy the "Sequence" method using a regex for the nxsd:startsWith value it seemed to put my BPEL Process into an infinite loop consuming 100% CPU. I had to kill the app server to stop it.
    A detailed reference on how the File Adapter processes files and what functions are available for ignoring bad records and/or conditional processing would be appreciated. Also, any more ideas on how to get this file parsed would be appreciated.

  • File processing in FIle adapter

    Hi,
    i have configured Sender File Adapter (FTP) in my scenario which picks the file from FTP folder and sends to JDBC.
    now i have 2 flat files in my FTP (yesterdays and todays). file names are test_07062010 and test_08062010.
    now my requirement is while processing the files, my file adapter has to process first file as test_07062010 and then test_08062010. but now it is processing first test_08062010 and then test_07062010. due to this yesterdays data is overwriting on todays data in Database.
    i know we have some option in file sender adapter (NFS)...but i need to do with FTP file sender...please let me know how to proceed further.
    Thanks in Advance.

    Hi Praveen...thanks for reply
    my communication channel is active all the days. but sometimes due to PI server down or some maintance we will stop channels.
    that time file will not pick by file sender and it will be in FTP.then next day one more file will generate in FTP. 
    So my proble is while processing these files my sender file adapetr is processing todays file first and then yesterdays.due to this yesterdays data is overwriting on todays data.
    can you tell me how to handle that in file adapter.

  • File to JDBC Adapter

    Hi All
    I am trying to configure File to JDBC Adapter to insert data in the database .I am having problem with message mapping.I  get the error with the statement field in mapping .Please can anyone let me know what mapping changes need to be done
    My Mapping is as follow
    SOURCE                                                          TARGET
    MT_INFO_DATA----
    >MT_JDBC_REC
    Header----
    > Statement
                                                               TABLENAME
    Update_insert----
    >Action
      T_EMPLOYEE(TABLE NAME)----
    > TABLE
                                                                   ACCESS
    EMP_NO----
    >EMP_NO
    COMP_ID----
    >COMP_ID
    BRANCH----
    >BRANCH
    Error: TransformException error in xml processor class: Error processing request in sax parser: Error when executing statement for table/stored proc. 'T_EMPLOYEE' (structure 'STATEMENT'): java.sql.SQLException: FATAL ERROR document format: structure 'STATEMENT', no key element found
    Please can anyone let me know what is to be mapped with the field STATEMENT.
    Thanks
    Amit

    Hi Bhavesh
    I did as suggested but still i am getting the following error
    Error: TransformException error in xml processor class: Error processing request in sax parser: Error when executing statement for table/stored proc. 'T_EMPLOYEE' (structure 'STATEMENT'): java.sql.SQLException: ORA-01861: literal does not match format string
    - 2007-05-24 06:21:17 IST: Processing started
    - 2007-05-24 06:07:48 IST: Error: TransformException error in xml processor class: Error processing request in sax parser: Error when executing statement for table/stored proc. 'T_EMPLOYEE' (structure 'STATEMENT'): java.sql.SQLException: FATAL ERROR document format: structure 'STATEMENT', no key element found
    - 2007-05-24 06:07:48 IST: Processing started
    - 2007-05-24 06:05:48 IST: Error: TransformException error in xml processor class: Error processing request in sax parser: Error when executing statement for table/stored proc. 'T_EMPLOYEE' (structure 'STATEMENT'): java.sql.SQLException: FATAL ERROR document format: structure 'STATEMENT', no key element found

  • Is XI Mapping dependent on the Adapter Type ??? JDBC  versus File Adapter

    Gretings,
    I am setting a scenario JDBC (Access) -> XI -> Idoc ->R3.
    First I set up the scenarion File ->XI ->IDOC. Everything worked fine, and the I tried to use JDBC adapter instead of the File Adapter. The JDBC adapter is able to retrieve the data from the Access Database but I got a mapping problem only the Idoc control record was filled, the data segment are empty.
    This mapping was working fine in the case of a File adapter !!!
    Here is the XML File in a case of File Adapter :
      <?xml version="1.0" encoding="UTF-8" ?>
    - <ns:POS_TRANSACTION xmlns:ns="http://aramco.com/XI/POS_OIL">
      <DATE>11/17/2004</DATE>
      <TIME>08:25:03</TIME>
      <TRANS_CODE>01</TRANS_CODE>
      <CUSTOMER>1235</CUSTOMER>
      <AMOUNT>105</AMOUNT>
      <POS_ID>1000</POS_ID>
      </ns:POS_TRANSACTION>
    And then The XML file in a case of JDBC adapter :
      <?xml version="1.0" encoding="utf-8" ?>
    - <ns:POS_TRANSACTION xmlns:ns="http://aramco.com/XI/POS_OIL">
    - <row>
      <DATE>11/17/2004</DATE>
      <TIME>00:00:07</TIME>
      <TRANS_CODE>01</TRANS_CODE>
      <CUSTOMER>23456</CUSTOMER>
      <AMOUNT>1456</AMOUNT>
      <POS_ID>1000</POS_ID>
      </row>
      </ns:POS_TRANSACTION>
    what is really strange is SAP XI mapping process should be adapter independent ! why am I having this problem ?
    Any help is more than welcome.
    Regards,
    Mustapha

    Hallo Mustapha,
    as far as i know, it is currently not possible to omit the row tag. Looking at the technique behind it, it makes sense: the JDBC Adapter polls a database with an SQL Statement and what gets back from the database is a resultset with zero, one or more rows (compare JDBC Classes, where you have java.sql.ResultSet). I guess, that maybe in later versions, it could be possible to customize the row tag to any name you want, but it will never be possible to completely omit it, as SQL statements can retrieve several rows and then you need to be able to differentiate between the rows. 
    best regards
    Christine

  • JCBC Adapter and File adapter not processing messages

    Hi
    I noticed that messages are being delivered to Adapter engine and the same are visible in Runtime Workbench with status "to be delivered". But, JDBC Adapter and File Adapter not processing these messages.
    Any idea where I can find the problem?
    I was able to re-deliver successfully via the JDBC Adapter using the MessagingSystem GUI using XISUPER user.
    Regards
    Chandu

    Hi,
    1.Status: TO_BE_DELIVERED
    Which means that the message was successfully delivered from Integration Server point of view and it states that the messages is initially handed over to the Messaging System.
    TO_BE_DELIVERED occurs while the message is put into the Messaging System receive queue.
    Regards
    Agasthuri Doss

  • Need help with a simple process with FTP Adapter and File Adapter

    I am trying out a simple BPEL process that gets a file in opaque mode from a FTP server using a FTP adapter and writes it to the local file system using a File Adapter. However, the file written is always empty (zero bytes). I then tried out the FTPDebatching sample using the same FTP server JNDI name and this work fine surprisingly. I also verified by looking at the FTP server logs that my process actually does hit the FTP server and seems to list the files based on the filtering condition - but it does not issue any GET or RETR commands to actually get the files. I am suspecting that the problem could be in the Receive, Assign or Invoke activities, but I am not able identify what it is.
    I can provide additional info such as the contents of my bpel and wsdl files if needed.
    Would appreciate if someone can help me with this at the earliest.
    Thanks
    Jay

    persiandude wrote:
    Topic: Need help with if, else, and which statements and loops.
    How would I display 60 < temp. <= 85 in java
    System.out.println("60 < temp. <= 85 in java");
    another question is how do I ask a question like want to try again (y/n) after a output and asking that everytime I type in yes after a output and terminate when saying No.Sun's [basic Java tutorial|http://java.sun.com/docs/books/tutorial/]
    Sun's [New To Java Center|http://java.sun.com/learning/new2java/index.html].Includes an overview of what Java is, instructions for setting up Java, an intro to programming (that includes links to the above tutorial or to parts of it), quizzes, a list of resources, and info on certification and courses.
    [http://javaalmanac.com|http://javaalmanac.com]. A couple dozen code examples that supplement [The Java Developers Almanac|http://www.amazon.com/exec/obidos/tg/detail/-/0201752808?v=glance].
    jGuru. A general Java resource site. Includes FAQs, forums, courses, more.
    JavaRanch. To quote the tagline on their homepage: "a friendly place for Java greenhorns." FAQs, forums (moderated, I believe), sample code, all kinds of goodies for newbies. From what I've heard, they live up to the "friendly" claim.
    Bruce Eckel's [Thinking in Java|http://mindview.net/Books/DownloadSites] (Available online.)
    Joshua Bloch's [Effective Java|http://www.amazon.com/Effective-Java-2nd-Joshua-Bloch/dp/0321356683/ref=pd_bbs_1?ie=UTF8&s=books&qid=1214349768&sr=8-1]
    Bert Bates and Kathy Sierra's [Head First Java|http://www.amazon.com/exec/obidos/tg/detail/-/0596004656?v=glance].
    James Gosling's [The Java Programming Language|http://www.bookpool.com/sm/0321349806].

Maybe you are looking for