File-splitting based on content.

Hi Experts,
This question is regarding file-splitting.
Its a BAI2 file with multiple records in it.
a)I need to split the file based on an identifier and make those many sub-files ( with header and trailer added to the file )
b)And can we ensure we have the same name for the files? ( with a count suffixed in the end )
The forum talks about BPM, Enhanced Interface/Receiver Determination, Message Mapping split etc..
Which would be the best approach for this?
Please advise.
Thank you,
Rakesh.

Hi,
Using Enhanced Interface/Receiver Determination approach is best one.
1.If your version is 7.1 and above, you can also try using enhanced interface determination. Please go through the below link
http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/90dcc6f4-0829-2d10-b0b2-c892473f1571?QuickLink=index&overridelayout=true
2.In the Receiver Determination, you need to select " Extended" in the Type of Receeiver determination.
Illustration of Enhanced Receiver Determination - SP16
regards,
ganesh.

Similar Messages

  • File Split based on Condition

    Hello
    I have a scenario where I get a file and need to split it into two based on a condition. Is it possible to accomplish this scenario at the file adapter configuration or do I need a mapping for this.
    Sample File 
    ABC1234asdfasfasdfasdfsdfasdfsdfsdfsdfasfsdfasdfsfasdfNewafasfsdfasfasdfasfafsdas
    asfdasdfasfasdfasdf
    asdfasdfadfasdfasfsd asdfsadfa fs
    asdfasdfasfasdfasdfasdfadfsfafasfas
    ABC1234asfdjoawejasdlfasdfasdfjsdfljasfjsfjaslfjasldfjasdlfsdOldfsdfadsfadfsdfasdffasdfasdfads
    asdfasdfsdfa
    asfdasdfasdfasdf
    asdfsfasfsfsad
    fasfasfasdffas
    asdfasfsfa
    asdfasfasfasdfas
    ABC1234asfdjoawejasdlfasdfasdfjsdfljasfjsfjaslfjasldfjasdlfsdNewfsdfadsfsd23424324234234234
    asdfsfasdfasfasfasfasfa
    asdfasfasdfasfasfaasdfa
    in the above content record always start with ABC1234 and it can have multiple sub records and it has a value new or old at column 120-123 in the first line of each record, it can have many sub records but I need to consider ABC1234 as the new record. I need to split the file into two, like one as newdata.txt and other as olddata.txt with new and old records respectively.
    Files after the split should look like this
    newdata.txt
    ABC1234asdfasfasdfasdfsdfasdfsdfsdfsdfasfsdfasdfsfasdfNewafasfsdfasfasdfasfafsdas
    asfdasdfasfasdfasdf
    asdfasdfadfasdfasfsd asdfsadfa fs
    asdfasdfasfasdfasdfasdfadfsfafasfas
    ABC1234asfdjoawejasdlfasdfasdfjsdfljasfjsfjaslfjasldfjasdlfsdNewfsdfadsfsd23424324234234234
    asdfsfasdfasfasfasfasfa
    asdfasfasdfasfasfaasdfa
    olddata.txt
    ABC1234asfdjoawejasdlfasdfasdfjsdfljasfjsfjaslfjasldfjasdlfsdOldfsdfadsfadfsdfasdffasdfasdfads
    asdfasdfsdfa
    asfdasdfasdfasdf
    asdfsfasfsfsad
    fasfasfasdffas
    asdfasfsfa
    asdfasfasfasdfas
    I appreciate if any one can help me with this.
    Thanks in advance

    Hi,
    as stefan pointed already you can't do this using standard adapter functionality,
    you can do it in mapping easily,convert below code in to UDF it will work.
    String test = "ABCasdasasasABCadsfsddgfgABCggdgdgdgdgABC34343";
    myString =test.split("ABC");
    for(int i=0;i<=myString.length;i++)
    System.out.println("MY STRING " + myString<i>);
    Regards,
    Raj

  • File splitting based on 3 parameterrs

    Hello experts,
    my requirement: i have to split a file based on country, then number of records, and finally based on whether records or historical or inventory.
    I have done till splitting using country and number of records, ie, if the user specifies number of records, 50000, it will generate files containing 50k records.
    Now the new requirement states that on top country and number of records, i need to split the file bases on historical or inventory, the data will have HIS or INV prefixed for all the records.
    The user should have the ability ti split only on HIS or INV, he can specify both, HIS and INV. The logic should split accordingly.
    Please assist me in this,
    thanks and regards
    Abhishek

    Hi Abhishek,
    A case transform will work in your case where in you specify a match pattern for historical(HIS%%%) and Inventory(INV%%).
    You can also use a batch command script to rename the excel/txt files with HIS_%%% or INV_%% once the file has been loaded with data.
    Regards
    Arun Sasi

  • Merge files...... pick file dynamically Based on your content

    Hi All,
    In my current scenario I have 2 dependent sources (Proxy and File system) from which data is being sent to a common target service. The sources are dependent on Proxy/ECC to File System. Please let me know how I need to pick the file from File system because lot of files are there in File System. Based on my ECC/Proxy message details on field of ABN, according ABN number I need to be pick the file from the File system but I have lot of files in File system. Please let me know how to pick multiple files from one correct file based on my first file message.
    After that picking the files I need merge the two messages and send to target file system.
    Using fork I can merge files, no issues. But here problem to pick file dynamically Based on content .
    Please provide your input......
    Regards,
    Ramesh

    Hi Ramesh Sir,
    You can go for JAVA Type Message Mapping.
    ECC - >  JAVA BASED MESSAGE MAPPING ( HERE WE WILL PERFORM FILE LOOKUP) - > RECEIVER .
    Is This approach sounds fisible to you ?
    Please provide Sender DataType XML / Receiver DataType XML + any 1 csv file in which lookup has to perform.
    and this approach is only possible , if your Flat file is on FTP Server which is on the same network.
    Regards
    Prabhat Sharma.

  • SAP PI 7.3.1 File Adapter - Select file based on content

    Hi all,
    I have a scenario where I need to process a file differently based on the content within the payload.
    For example a file called File_IS,xml is sent to a folder that PI is polling. Within this file is a field <TYPE> which I want to use to determine whether the file should be used  . I have two mapping scenarios that each have a file sender communication channel polling for the same file name "File_IS.xml" .  This is because a message will come from a 3rd party with the same file name but the content can be different meaning different mapping scenarios are required.  IF Com_Channel_1 sees the File I only want it to be picked up if say <TYPE> = 'A' - if not then Com_Channel_1 should do nothing with this file.  Similarly Com_Channel_2 should only use the file if <Type> = 'B'. 
    Scenario:
    File_IS.xml       -> File sender 1  -> <TYPE> = 'A'  - Pick up file - do mapping - archive.  <TYPE> <> 'A' - do nothing and leave file in folder
                          ->  File sender 2  -> <TYPE> = 'B'  - Pick up file - do mapping - archive.  <TYPE> <> 'B' - do nothing and leave file in folder
    Is the above possible at all ?
    Thanks for your time.
    Best Regards.
    Gary

    Hello,
    In case content of input files are different (for both the scenarios) even then also u can use one file sender channel. Check below approach:
    Interface Determination condition
    Thanks
    Amit Srivastava

  • Content Server with File System Based Content Repository

    Typically the SAP Content Server is installed with a SAPDB database. The content server software serves the content from the content repository - the SAPDB database.
    I recall reading a few years ago about (unofficial?) plans from SAP to support file system based repositories, with the content server controlling access. So from a KPRO application perspective, whether the document was in a database or on a filesystem is hidden.
    Can anyone tell me whether this is available yet? And if so, under Windows operating systems?
    Regards
    Andrew

    HI Frank Weitzdörfer  ,
    Could you share about architecture of this scenario ?
    Can I use a simple PC as content repository and keep content server  and R/3 System in the same box and define some link between CS & PC based repository.
    Regards
    Gopal Jaiswal

  • How to Split the message content?

    Hi ....
        I am having an input File like below format.
    <?xml version="1.0" encoding="UTF-8"?>
    <ns0:MT_ISO8583 xmlns:ns0="http://axis.com/bank_statement">
       <Field1></Field1> -
    0 to 1
       <Filed2></Filed2> -
    0 to 1
       <Filed3></Filed3> -
    0 to unbounded
    </ns0:MT_ISO8583>
    Here Field 3 is repeating many times. The value in the Field 3 has to be splitted and should be mapped to the target feilds. Field 3 will stop repeating until when the first value in the field 3 is N.
    The length of the field is 142 characters in length.
    The field should be splitted based on the following structure.
    More data flag : 1 char (u2018Yu2019/u2019Nu2019) This indicates whether there are more records for the given criteria.
    Number of statements : 2char (00 to 20) Number of statements in this fetch
    The following are repeated as many number of statements
    Transaction date : 8 char ( YYYYMMDD )
    Transaction Id : 9 char (right justified, left padded with spaces)
    Part tran serial num : 4 char (right justified left padded with spaces)
    Tran Type : 1 char ( C - Cash, T - Transfer, L - Clearing )
    Tran sub type : 2 char ( BI, CI, NP, NR)
    Debit credit indicator : 1 char ( D - Debit, C - Credit )
    Tran value date : 8 char ( YYYYMMDD )
    Transaction Amount : 17 char ( with decimal )
    Transaction particulars : 50 Char (left justified, right padded with spaces)
    Transaction Posted date : 14 char ( YYYYMMDDHHMISS )
    Instrument number : 8 char (right justified, left padded with spaces)
    Balance at the end of the transaction : 17 char ( with decimal )
    Can you help me , how to split the message content in the field3?
    Below is the sample message.
    <?xml version="1.0" encoding="UTF-8"?>
    <ns0:MT_ISO8583 xmlns:ns0="http://axis.com/bank_statement">
       <Field1>930000</Field1>
       <Filed2>234259901406</Filed2>
       <Filed3><Y0820090127S275433861005TBIC20090127 4872.14EDC/212-213-/M000044375340045 20090127151 959 32663.7620090127S278456264276TBIC20090127 5290.45EDC/214-215-/M000044375340045 20090127205840 37954.2120090131S299799314797TBIC20090131 1883.88EDC/216-216-/M000044375340045 20090131104028 39838.0920090202S31532814 662TBIC20090202 3105.37EDC/217-217-/M00004 4375340045 20090202121514 42943.4620090205S337981634779TBIC20090205 2052.20EDC/2 18-218-/M000044375340045 20090205104040 44995.6620090205 M53898 1CNPD20090205 42000.00TO CASH/SELF 20090205111633 12824 2995.6620090207S354072734740TBIC20 090207 4429.21EDC/219-219-/M000044375340045 20090207112958 7424.8720090209S3671 72631419TB Field 126: IC20090209 7161.55EDC/220-221-/M000044375340045 20090209122637 14586. 42]]></Filed3>
       <Filed3><Y0820090127S275433861005TBIC20090127 4872.14EDC/212-213-/M000044375340045 20090127151 959 32663.7620090127S278456264276TBIC20090127 5290.45EDC/214-215-/M000044375340045 20090127205840 37954.2120090131S299799314797TBIC20090131 1883.88EDC/216-216-/M000044375340045 20090131104028 39838.0920090202S31532814 662TBIC20090202 3105.37EDC/217-217-/M00004 4375340045 20090202121514 42943.4620090205S337981634779TBIC20090205 2052.20EDC/2 18-218-/M000044375340045 20090205104040 44995.6620090205 M53898 1CNPD20090205 42000.00TO CASH/SELF 20090205111633 12824 2995.6620090207S354072734740TBIC20 090207 4429.21EDC/219-219-/M000044375340045 20090207112958 7424.8720090209S3671 72631419TB Field 126: IC20090209 7161.55EDC/220-221-/M000044375340045 20090209122637 14586. 42]]></Filed3>
       <Filed3><Y0820090127S275433861005TBIC20090127 4872.14EDC/212-213-/M000044375340045 20090127151 959 32663.7620090127S278456264276TBIC20090127 5290.45EDC/214-215-/M000044375340045 20090127205840 37954.2120090131S299799314797TBIC20090131 1883.88EDC/216-216-/M000044375340045 20090131104028 39838.0920090202S31532814 662TBIC20090202 3105.37EDC/217-217-/M00004 4375340045 20090202121514 42943.4620090205S337981634779TBIC20090205 2052.20EDC/2 18-218-/M000044375340045 20090205104040 44995.6620090205 M53898 1CNPD20090205 42000.00TO CASH/SELF 20090205111633 12824 2995.6620090207S354072734740TBIC20 090207 4429.21EDC/219-219-/M000044375340045 20090207112958 7424.8720090209S3671 72631419TB Field 126: IC20090209 7161.55EDC/220-221-/M000044375340045 0090209122637 14586. 42]]></Filed3>
       <Filed3><N0820090127S275433861005TBIC20090127 4872.14EDC/212-213-/M000044375340045 20090127151 959 32663.7620090127S278456264276TBIC20090127 5290.45EDC/214-215-/M000044375340045 20090127205840 37954.2120090131S299799314797TBIC20090131 1883.88EDC/216-216-/M000044375340045 20090131104028 39838.0920090202S31532814 662TBIC20090202 3105.37EDC/217-217-/M00004 4375340045 20090202121514 42943.4620090205S337981634779TBIC20090205 2052.20EDC/2 18-218-/M000044375340045 20090205104040 44995.6620090205 M53898 1CNPD20090205 42000.00TO CASH/SELF 20090205111633 12824 2995.6620090207S354072734740TBIC20 090207 4429.21EDC/219-219-/M000044375340045 20090207112958 7424.8720090209S3671 72631419TB Field 126: IC20090209 7161.55EDC/220-221-/M000044375340045 20090209122637 14586. 42]]></Filed3>
    </ns0:MT_ISO8583>
    Thanks & Regards,
    Leela

    using substring to get values you want, and map to corresponding target nodes except:
       fields3 ->count->Number of statement
    Regards.
    Liang

  • XML File splitting in PI

    Hi all,
    We have a requirement that the receiving application can accept files only of size 2MB. So this is a limitation from the receiving application
    The source system is SAP ECC system and the receiving application is a legacy application.
    Technically it is a ABAP Proxy to File scenario. Receiving application can accept files only in XML format.
    SAP ABAP Proxy code is written in such a way to read all the records in a SAP table and the full table load is sent as an proxy xml message to PI, PI has to split this  full xml file  in to chunks based on some condition and then transfer it to receiving legacy application.
    Can we achieve file splitting in PI for XML files based on no.of records or size.
    Please share your inputs/pointers to provide the best solution to this requirement.
    regards,
    Younus

    Hi,
    Yes this can be done by the amount of records you send through at a time.
    So lets there is 10000 records. You might only send 200 at a time and that will keep it under the 2mb limitation.
    This is a simple if function on your nodes. Please see the links below that would help you.
    Split source message into multiple target messages
    Defining Message Splits - SAP NetWeaver Process Integration - SAP Library
    Configuring Mapping-Based Message Splits - Integration Directory - SAP Library
    Split mapping created no messages SAP PI 7.11
    http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/30ea2fdf-f047-2a10-d3a2-955a634bde6b?overridelayout=t…
    Regards,
    Jannus Botha

  • Idoc to File Split Scenario..

    HI Experts,
    My scenario is Idoc to File split scenario..
    Idoc will be triggered from the SAP ECC system and at the target side we need to drop two text files at the ftp directory.
    so Idoc data needs to be splitted and to be dropped in two differient files in the target FTP directory..
    So can any one suggest how to go ahead with the scenario..
    Thanks,
    --Kishore.

    Hi,
    In the idoc, some of the data will go to onefile and some goes to other files..
    the structures of the two files are differient..
    There is no condinal spliting here every idoc contents should be mapped according to the requirement and dropped as two files.. at the target end.
    for ex:
    Idoc
    field1
    fileld2
    field3
    field4
    in the out put side
    file1 should contain
    field1
    field3
    field4
    file2 should contain
    field1
    field2
    fileld3
    This is what the requirement, if you are not getting reply back with your queries..
    Thanks,
    --Kishore..

  • Logging option on file adapter based JNDI

    Hello,
    While setting up a file adapter based JNDI, I notice under outbound connection, we have logging option where we have rotate logs based on size/time. Could someone please help me understand what does this refers to and how we can use that.
    its under - Deployment -> File adapter -> Outbound connection -->"Select a JNDI created by you" -> Logging.
    my JNDI, represent to a location where I am writing few specific log content in a text file. Can we handle(rotate) that based on this.
    Pls advice.

    Hi,
    you need to create 40 channels if you have users
    as dynamically you can only create:
    File Name
    Directory
    File Type
    File Encoding
    Temporary Name Scheme for Target File Name
    with FTP adapter
    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>

  • Another case of file splitting

    Hello
    I need your help to find the easier way to develop this kind of interface :
    My source file have a variable number of records.
    I would like to create as target datastores as much files as sets of a kixed number of records :
    For example : This fixed number of records is 10 and my source datastore has 83 records :
    I would like to obtain
    9 files : the first with the first 10 records, the second with de 10 next and so on untill the last that will contain the last 3 records
    I guess I have to use a sequence ???

    Hi,
    Yea, you need to use sequence to do this task,
    Better to create the temp table for source file use sequence here(while uploading source file to temp table).From the table you can split it as mush file required based on number of records
    Thanks
    Madha

  • Very large files checkin to DMS/content server

    Dear experts,
    We have DMS with content server up and running.
    However, there is a problem with very large files (up to 2GB!) - these files cannot be checked in due to extremely long upload times and maybe GUI limitations.
    Does anyone have suggestions how we could get very large files into the content server ? I only want to check them in (either via DMS or directly to the content server) and then get the URL back.
    best regards,
    Johannes

    Hi Johannes,
    unfortunatly there is a limit for files regarding the Content Server which is about 2GB. Please note that such large files will cause very long upload times. If possible I would recommend you to split the files to smaller parts and try to check it in.
    From my point of view it is not recommended to put files directly on the Content Server, because this could lead to inconsistencies on the Content Server.
    Best regards,
    Christoph

  • Undesiarable Delivery split based on customer group

    Hi Gurus,
    This is very urgent,
    One of my business requirement is to avoid splitting of Delivery when the reference sales order contains line items that belong to different customer group.
    I have a sales order with three line items. Two of which belong to one customer group and one belong to another customer group. When delivery is created it gets split into two based on the customer group. But I dont want splitting based on customer group.
    Is there any SRO settings or enhancement or SAP note etc available for this purpose.
    Helpful answers will be rewarded.
    Thanks in advance
    Ramachandran Babu

    This is indeed the routine I was referring to. This ZUKRL field is created for each order and only orders with exactly the same content in this field will be or can be combined into one delivery.
    However, I don't see customer group here (only distribution channel and division), so this will not be the cause of your problem.
    Regards,
    John.

  • How can we upload file into to OCS Content repository when we are in Apex

    We have installed the Oracle Application Express 2.2.1 into the OCS 10.1.2 database.
    The Apex authentication is set to operate with OCS SSO.
    We have made a form. There is a browse button on the form. We would like if the uploaded file appeared in the OCS content database repository as
    opposed to Apex document repository.
    To put it into another word, how can we upload the file into to OCS Content repository when we are in Apex.
    Generally speaking, how can we reach content from Apex?
    We have found many java based examples to use content sdk, but how can we use them with Apex? We believe that
    content hasn't got plsql interface.
    i would highly appreciate it if you sent me a full example program.

    Hi Ram,
    Thanks for the reply
    We have a requirement to device a solution to upload the policy documents related to iProcurement
    I am planning to create an OA page to upload the content and planning to use the AOL function security to restrict the users those who can access this page .
    Is there any better way to implement the security?
    Is this approach feasible or is there any better way to approach this requirement?
    Thanks

  • My home page is google and it works but when I open a new tab it displays an error message :Firefox can't find the file at chrome://quick_start/content/index.ht

    I've made sure a dozen times that my home page is set correctly, and when I hit the home button next to the search bar it works and takes me right to google BUT whenever i open a new tab i get the error that my page cannot load and the web url that it keeps trying to remember is in the error message:
    Firefox can't find the file at chrome://quick_start/content/index.html.
    of course the last dot is not the url anymore but the end of the sentence for the error message, but i don't ever use chrome ever on my laptop only my cell so what is going on????? help fix god please!!!!!!

    Do you have the FastStart extension?
    Start Firefox in <u>[[Safe Mode|Safe Mode]]</u> to check if one of the extensions (Firefox/Tools > Add-ons > Extensions) or if hardware acceleration is causing the problem.
    *Switch to the DEFAULT theme: Firefox/Tools > Add-ons > Appearance
    *Do NOT click the Reset button on the Safe Mode start window
    *https://support.mozilla.org/kb/Safe+Mode
    *https://support.mozilla.org/kb/Troubleshooting+extensions+and+themes

Maybe you are looking for

  • Site edit not recognizing index.htm file

    Going through the Site/Edit function to change server information, DW told me it can't find the index.htm file. Waiting on more information from the host - beside the new IP address, the password has been changed and the upload path. While I'm waitin

  • How to delete old/other Apple ID's from iPad

    So about every 10 minutes my new iPad tries to download (or update) apps or songs that were purchased with a different Apple ID than mine.  I know one was my old room mates.  This didn't happen on my iPad 2 (got the new ipad 2 days ago). Any idea how

  • New HD and OS installed, but system gets slower as time goes by

    I have just put in a new 250GB HD, a new DVD-R drive, and installed a new OS(10.4.11). When the Powerbook first boots up, it works fine, but as time goes by(just a few minutes even), the system gets bogged down and eventually grinds to a halt. I've b

  • What is the best way to allow one to send an email? Confused.

    Hi, I researched on the forum for the ability to have someone click a button and be able to have a blank email pop up.  I use to use this all the time. However my question is since Outlook Express (and for that matter now Windows mail) are no longer

  • Problem with PDF Output

    Hi all,i am new to Oracle Apps.Today i happen to show the PDF o/p from my form.I created the template and attached in the XML publisher responsibility.But,when i try to run the form i can't see the PDF o/p,instead i get the XML o/p.Can anyone kindly