Combining 2 files and mapping it to a single destination file

hi all;
if i am combining 2 files and mapping it to a single destination file then do we need to define 2 sender communication channels and 1 receiver communication channel

i have done with the BPM.
steps
1 Block with corelation name
2 Fork with end condition counter not equal 2
3 fork branch 1 -- receive with corelation and container incrementing count by 1
  fork branch 2 -- receive with corelation and container incrementing count by 1
4 transformation
5 send
i have source file structure during mapping:
<?xml version="1.0" encoding="UTF-8"?>
<ns0:Messages xmlns:ns0="http://sap.com/xi/XI/SplitAndMerge">
   <ns0:Message1>
      <ns1:SenderData1 xmlns:ns1="http://multimapping.com">
         <Name>AAAA</Name>
      </ns1:SenderData1>
   </ns0:Message1>
   <ns0:Message2>
      <ns1:SenderData2 xmlns:ns1="http://multimapping.com">
         <Name>BBBB</Name>
      </ns1:SenderData2>
   </ns0:Message2>
</ns0:Messages>
i breaked the structure in 2 and placed it in different files
<?xml version="1.0" encoding="UTF-8"?>
<ns0:SenderData1 xmlns:ns0="http://multimapping.com">
   <Name>AAAA</Name>
</ns0:SenderData1>
<?xml version="1.0" encoding="UTF-8"?>
<ns0:SenderData2 xmlns:ns0="http://multimapping.com">
   <Name>BBBB</Name>
</ns0:SenderData2>
is that all to be done

Similar Messages

  • PI 7.1 : Taking a input PDF file and mapping it to a hexBinary attribute

    Hello All,
    We have a requirement which involves taking in an input PDF file and mapping it to a message type with binary attribute and sending it to an R3 system.
    Can anyone please detail the steps or point us to the correct documents for setting up the scenario.
    The scenario is file to Proxy adapter. The part which we need assitance is pulling up the input pdf and mapping it to binary field.
    Thanks.
    Kiran

    Thanks Praveen,Mayank,Sarvesh and Andreas for your  valuable help with the issue.
    I was able to successfully pick up the binary PDF file from a file server , encode it using Base 64 and post it to R3.
    I used the following code snippet and added the mentioned jar files to create a new jar file which was used as java mapping in the operation mapping.
    import com.sap.aii.mapping.api.StreamTransformation;
    import com.sap.aii.mapping.api.*;
    import com.sap.aii.utilxi.base64.api.*;
    import java.io.*;
    import java.util.*;
    public class Base64EncodingXIStandard implements StreamTransformation{
         String fileNameFromFileAdapterASMA;
         private Map param;
         public void setParameter (Map map)
              param = map;
              if (param == null)
                   param = new HashMap();
         public static void main(String args[])
              Base64EncodingXIStandard con = new Base64EncodingXIStandard();
              try
                   InputStream is = new FileInputStream(args[0]);
                   OutputStream os = new FileOutputStream(args[1]);
                   con.execute(is, os);
              catch (Exception e)
                   e.printStackTrace();
    public void execute(InputStream inputstream, OutputStream outputstream)
                   DynamicConfiguration conf = (DynamicConfiguration) param.get("DynamicConfiguration");
                   DynamicConfigurationKey KEY_FILENAME = DynamicConfigurationKey.create("http://sap.com/xi/XI/System/File","FileName");
                   fileNameFromFileAdapterASMA = conf.get(KEY_FILENAME);
                   if (fileNameFromFileAdapterASMA == null)
                        fileNameFromFileAdapterASMA = "ToBase64.txt";
              try
                   while ((len = inputstream.read(buffer)) > 0)
                        baos.write(buffer, 0, len);
                   str = Base64.encode(baos.toByteArray());     //buffer);
                   outputstream.write("<?xml version=\"1.0\" encoding=\"utf-8\"?><ROOT>".getBytes());
                   outputstream.write(("<FILENAME>" + fileNameFromFileAdapterASMA + "</FILENAME>").getBytes());
                   outputstream.write( ("<BASE64DATA>" + str + "</BASE64DATA></ROOT>" ).getBytes());
              catch(Exception e)
                   e.printStackTrace();
         byte[] buffer = new byte[1024*5000];
         ByteArrayOutputStream baos = new ByteArrayOutputStream();
         int len;
         String str = null;
    I had to do the following configuration settings
    1)  Create a Sender Comm Channel with Adapter Specific message attributes and Filename checkbox checked.
    2) Use the Java Mapping in the Operation mapping.
    The scenario is working smoothly with out any issues.
    Thanks.
    Kiran

  • Problem in Creating .wsdl file and mapping.xml with ant

    hi
    i am created my .wsdl file and mapping.xml file with wscompile tool but when i run this by ant tool it show a problem.
    the command runs on command prompt but when run throught ant file it shows a following error :-
    Execute failed: java.io.IOException: CreateProces: wscompile -define -mapping build\classes\META-INF\mapping.xml -d . -nd build\.................and so on
    so if anybody have any idea then plz help me asap
    thanx

    The following Ant snippet is the way I've defined my wscompile task. I'm creating a web application and it looks like yours might be an EJB endpoint, but you can adjust where necessary:
    <taskdef name="wscompile" classname="com.sun.xml.rpc.tools.ant.Wscompile">
         <classpath refid="compile.classpath" />
    </taskdef>
    <target name="init">
         <echo message="-------- ${appname} --------" />
    </target>
    <!-- This target compiles the server components using an existing WSDL as the driving document.
           The configuration file must use the <wsdl> element giving the location (local file system
           or URL) of the WSDL document.
           Note: the fork argument is needed to over come a bug when using the mapping argument. See
           http://forum.java.sun.com/thread.jspa?threadID=592994&tstart=0
      -->
         <target name="generate-server-from-WSDL" depends="init">
              <wscompile fork="yes"
                           keep="true"
                           base="${basedir}/WebContent/WEB-INF/classes"
                           import="true"
                           features="wsi"
                           xPrintStackTrace="true"
                           verbose="true"
                           mapping="${basedir}/WebContent/WEB-INF/jaxrpc-mapping.xml"
                           sourcebase="${basedir}/src"
                           config="${config.server.doclit.file}">
                   <classpath>
                        <path refid="compile.classpath" />
                   </classpath>
              </wscompile>
         </target>
         <target name="compile-server-from-WSDL" depends="generate-server-from-WSDL">
              <javac srcdir="${basedir}/src" destdir="${basedir}/WebContent/WEB-INF/classes" debug="${compile.debug}">
                   <classpath refid="compile.classpath" />
              </javac>
         </target>Just make sure that the named destination directories exist before you run the script.
    If you'd like more details on the wscompile Ant task, I found the following pages invaluable:
    https://jax-rpc.dev.java.net/whitepaper/1.1/index-part1.html

  • I installed a game, where can i find the files and maps? where does iMac store this data?

    I installed a game,Now I need to add some files however, I cannot find where iMac stores it.. where can i find the files and maps? where does iMac store this data?
    thx alot
    erik

    Depends on game, i would look first on the game file itself, right click (or ctrl click) the game file you installed (Applications?) and select show package contents, its usually a application bundle, as in basicly a folder where the application and the required files and subfolders are.

  • How to search a special string in txt file and return it's position in txt file?

    How to search a special string in txt file and return it's position in txt file?

    I just posted a solution for a similar question here:  http://forums.ni.com/ni/board/message?board.id=170​&view=by_date_ascending&message.id=362699#M362699
    The top portion can search for the location of a string, while the bottom portion is to locate the position of a character.  Both can search for a character.
    The position of the character within the file is displayed in the indicator(s).
    R

  • One of the folders on my external hard drive has transformed into a unix executable file and I can no longer access my files. Is there any way to save the data?

    One of the folders on my external hard drive has transformed into a unix executable file and I can no longer access my files. Is there any way to save the data?

    Wow, have seen Files do that, but a whole Folder as I recall!
    Could be many things, we should start with this...
    "Try Disk Utility
    1. Insert the Mac OS X Install disc, then restart the computer while holding the C key.
    2. When your computer finishes starting up from the disc, choose Disk Utility from the Installer menu. (In Mac OS X 10.4 or later, you must select your language first.)
    Important: Do not click Continue in the first screen of the Installer. If you do, you must restart from the disc again to access Disk Utility.
    3. Click the First Aid tab.
    4. Select your Mac OS X volume.
    5. Click Repair. Disk Utility checks and repairs the disk."
    http://docs.info.apple.com/article.html?artnum=106214
    Then try a Safe Boot, (holding Shift key down at bootup), run Disk Utility in Applications>Utilities, then highlight your drive, click on Repair Permissions, reboot when it completes.
    (Safe boot may stay on the gray radian for a long time, let it go, it's trying to repair the Hard Drive.)

  • How to Compare 2 CSV file and store the result to 3rd csv file using PowerShell script?

    I want to do the below task using powershell script only.
    I have 2 csv files and I want to compare those two files and I want to store the comparision result to 3rd csv file. Please look at the follwingsnap:
    This image is csv file only. 
    Could you please any one help me.
    Thanks in advance.
    By
    A Path finder 
    JoSwa
    If a post answers your question, please click &quot;Mark As Answer&quot; on that post and &quot;Mark as Helpful&quot;
    Best Online Journal

    Not certain this is what you're after, but this :
    #import the contents of both csv files
    $dbexcel=import-csv c:\dbexcel.csv
    $liveexcel=import-csv C:\liveexcel.csv
    #prepare the output csv and create the headers
    $outputexcel="c:\outputexcel.csv"
    $outputline="Name,Connection Status,Version,DbExcel,LiveExcel"
    $outputline | out-file $outputexcel
    #Loop through each record based on the number of records (assuming equal number in both files)
    for ($i=0; $i -le $dbexcel.Length-1;$i++)
    # Assign the yes / null values to equal the word equivalent
    if ($dbexcel.isavail[$i] -eq "yes") {$dbavail="Available"} else {$dbavail="Unavailable"}
    if ($liveexcel.isavail[$i] -eq "yes") {$liveavail="Available"} else {$liveavail="Unavailable"}
    #create the live of csv content from the two input csv files
    $outputline=$dbexcel.name[$i] + "," + $liveexcel.'connection status'[$i] + "," + $dbexcel.version[$i] + "," + $dbavail + "," + $liveavail
    #output that line to the csv file
    $outputline | out-file $outputexcel -Append
    should do what you're looking for, or give you enough to edit it to your exact need.
    I've assumed that the dbexcel.csv and liveexcel.csv files live in the root of c:\ for this, that they include the header information, and that the outputexcel.csv file will be saved to the same place (including headers).

  • I am trying to open my files and I get the message that the file is invalid.  The index sml file is missing

    I am trying to open my files and get a message saying that the file is invalid.  The index xml file is missong

    Tell us the whole Story in detail about what App (if any), version, any changes you have made recently and Importantly, the exact message - verbatim - a screenshot of the entire display would be very helpful - ÇÇÇ

  • In Quicktime Pro I try to create a mov file and I get an error "-43 a file could not be found".  Any ideas?

    In Quicktime Pro I try to create a mov file and I get an error "-43 a file could not be found".  Any ideas?

    I have a similar problem which i did not have before...and it exists only in some powerpoint files which i want to print as a pdf file...and i get the same message as above.
    the log says the bellow details...what's the problem and how can i resolve it? thanks.
    %%[ ProductName: Distiller ]%%
    %%[Page: 1]%%
    %%[Page: 2]%%
    Cambria not found, using Courier.
    %%[ Error: invalidfont; OffendingCommand: show ]%%
    Stack:
      %%[ Flushing: rest of job (to end-of-file) will be ignored ]%%

  • Can I use a select and update statement in a single jsp file?

    I want to update the BUY table everytime I would add a SELL transaction.....I want to minus the stocks that I sold to those that Ive bought before.....
    note: I used a seperate table in BUY and SELL transaction
    After I Have added a transaction, I want to update the buy table. This is my problem, can I used both SELECT and UPDATE statement at the same time in a single jsp file for example like this:
    select * from test, test1;
    update test
    set total_shares=total_shares-Stotal;
    where stock_code=Scode AND name_broker=Sbroker;
    Can i have both of these statements in the same jsp file in oder to update the buy table?
    Or can anyone suggest how can process that update?THANKS!
    --------------------

    Can i have both of these statements in the same jsp file in oder to update the buy table?Yes. But wouldn't it have been easier just to try it?

  • Map files and map IDs

    This question was posted in response to the following article: http://help.adobe.com/en_US/robohelp/robohtml/WS5b3ccc516d4fbf351e63e3d11aff59c571-7ff9.ht ml

    Typo in this section:
    Remove an unused map ID
    Your map files must be unlocked to use this option. To remove unused map IDs:
    Expand the Context-Sensitive Help folder in the Project Set-up pod.
    Right-click the Map Files folder.
    Select Edit.
    Do the following:
    Map Files Select the map files from which to remove unused map IDs.
    Select All Click to remove unused map IDs from all map files.
    Clear All Click to deselect all map files and not remove unused map IDs.
    The third point should read "Select Remove Unused Map IDs..." instead of "Select Edit"; then the rest of the topic makes sense.

  • Applescript to open various files and add info from filename to the file

    Hi guys,
    first time using this forum...
    and first time trying to do a script for apple...
    I figured out how to do simple things... like open files and stuff to text files...  but don't know where to begin:
    I have a directory datalogs...
    within the directory i have multiple text files that have the following format:
    dataXXYYY_Waf2_7_19_11.csv
    dataXXYYY_Waf3_7_19_13.csv
    dataXXYYY_Waf25_7_19_16.csv
    typically 25 files, but sometimes less
    I would like to be able to take each file within the datalogs folder ...
    Scan the file name and look for the number afer Waf
    The number can be anywhere from (single digit) 1 to 25
    I would like to take that value after Waf  and then append a line in the txt file
    the line I would have to add will be 5 rows down and it shoulld say:
    wafer,1 
    the 1 above is the value that was in the file name....
    i.e.
    for the file
    dataXXYYY_Waf25_7_19_16.csv
    before append the file contains random data ... i.e.
    dummyline1
    dummyline2
    dummyline3
    dummyline4
    dummyline5
    dummyline6
    Then after the script...
    the file will be saved with same name:
    dataXXYYY_Waf25_7_19_16.csv
    and the data should look like:
    dummyline1
    dummyline2
    dummyline3
    dummyline4
    wafer,25
    dummyline5
    dummyline6
    any help will be appreciated
    -thanks

    Copy your source folder - named 'datalogs' to your home directory and run this script by copying into a new AppleScript Editor document and pressing Run. 
    I think I've followed your specification, and there will be other ways to do this, but ask if you have questions.  (I have put comments in the code which should explain some of it!)
    There is no error checking, but I have made copies of the original files in the source directory.  (You can comment out the line "duplicate theFile" by prefixing with "--" when you are sure it's working.
    As always, ensure your data is backed-up before proceeding.
    --starts here
    --sets path to datalogs folder
    set theDirectory to (path to home folder as text) & "datalogs"
    set fileNames to {}
    tell application "Finder"
      --gets all the files in the source directory
              set fileList to files of folder theDirectory
      --iterates through the files
              repeat with theFile in fileList
      --makes a duplicate
      duplicate theFile
      --puts the fileName and fileLocation into records in a list of lists
                        set end of fileNames to {fileName:name of theFile, fileLoc:theFile as alias}
              end repeat
      --iterates thru the files
              repeat with theFile in fileNames
      --gets offset of the string "Waf"
                        set WafOffset to offset of "Waf" in (fileName of theFile)
      --trims the name so that it now starts with the character after "Waf"
                        set fileName to text (WafOffset + 3) thru end of fileName of theFile
      --gets offset of the next underscore
                        set UScoreOffset to offset of "_" in fileName
      --stores the desired number by trimming off the end of the file name
                        set fileNumber to text 1 thru (UScoreOffset - 1) of fileName
      --sets up the text to insert by prefixing with "Wafer," and suffixing with return
                        set insertText to "Wafer," & fileNumber & character id 10
      --opens the file with write permission
                        set FileRef to open for access (fileLoc of theFile) with write permission
      --initialise container
                        set fileContents to ""
      --puts first five lines into container
                        repeat 5 times
                                  set fileContents to fileContents & (read FileRef until character id 10)
                        end repeat
      --adds the new text to the container
                        set fileContents to fileContents & insertText
      --adds the rest of the file to the container
                        set fileContents to fileContents & (read FileRef)
      --effectively empties the file
      set eof FileRef to 0
      --writes contents of the container to the file
      write fileContents to FileRef
      --closes the file
      close access FileRef
              end repeat
    end tell
    --ends here

  • How to get video file and iTunes Extra to show as one file in iTunes?

    When I purchase a movie in iTunes with iTunes Extras, after the download is finished in the "Movies" and "Genres" view they appear as one file. You click on the cover, it opens, shows the "Play iTunes Extra" button as well as a small Play arrow button next to the title to play the movie directly. Only in "List" view do they appear as separate files.
    How can I achieve that for my own iTunes extra? I tried giving the .ite the same XID as the movie file but that didn't work, they continue to appear as separate files in iTunes and the little play button when expanding the iTunes Extra doesn't work obviously. Anyone can tell me how this is done?

    Ok, I finally figured it out... there is 2 files that play a critical role in this
    first is manifest.xml
    in this file ensure that the library_item type string references the xid for your video file, and it has to be a proper xid. The iAd Producer manual explains how to create one if it does
    example:
    <library_item type="video" local_id="feature" xid="TEST:uuid:C7AE7CED-3F60-4C08-AA01-E3F9647B95CC" name="Your Movie"/>
    second file and even more critical is iTunesMetadata.plist. There is a couple of strings in there that lace the iTunes Extra to the film and vice versa
    <key>itemId</key>
    <integer>987654321</integer>
    <key>itemName</key>
    <string>Your Movie - iTunes Extras</string>
    The first is a unique 9 digit number that identifies your iTunes Extra file, the second is the name of the file that should follow the convention "Your Movie Title - iTunes Extras"
    <key>playlistId</key>
    <integer>123456789</integer>
    <key>playlistName</key>
    <string>Your Movie</string>
    This is what ties it back to the movie file, we will come back to it later where in the movie MetaData you need to place this 9 digit string
    <key>xid</key>
    <string>TEST:uuid:C7AE7CED-3F60-4C08-AA01-E3F9647B95CC_ITUNES_EXTRAS</string>
    This is the convention in how to properly xid your iTunes Extra, it is your movie's XID with "_ITUNES_EXTRAS" added to the end of it
    <key>Name File</key>
    <string>Your Movie - iTunes Extras.ite</string>
    <key>associated-adam-ids</key>
    <array>
    <integer>123456789</integer>
    The first is self explanatory but the second is again this 9 digit number that you will need to place into the meta data of your movie. It is what will make iTunes lace the two files together
    <key>xid-asset-mapping</key>
    <dict>
    <key>TEST:uuid:C7AE7CED-3F60-4C08-AA01-E3F9647B95CC</key>
    <array>
    <integer>123456789</integer>
    </array>
    <key>TEST:uuid:C7AE7CED-3F60-4C08-AA01-E3F9647B95CC_ITUNES_EXTRAS</key>
    <array>
    <integer>987654321</integer>
    </array>
    </dict>
    This is the last critical piece, it laces the two files tigthly together. Now the 9 digit number counting down from 9 is part of the unique ID of the iTunes Extra, the 9 digit number counting up from 1 needs to be put into the metadata of your movie. The annotation type for this is "contentID".
    That's pretty much it. If you did it right your files will now appear as one file in cover view just like a movie bought in the store.
    The easiest to do this right is to grab the manifest.xml and iTunesMetadata.plist from an iTunes store movie and copy paste and edit it for your purposes, which is what I did.
    Cheers everyone!

  • I have sent a file to the trash bin. When I come to empty the trash bin everything goes out except this one particular file and I get a note saying the file is 'in use' but it is not. How can I delete this file from trash?

    I have a Macbook Pro with OS X Lion 10.7.2. I have sent a work file to the trash bin along with many other files. When I empty the trash this one particular file remains and I get a message that this file is still in use. I have tried returning the file to my documents, opening it, closing it and then sending it to trash and again I try to empty trash but the same message comes up - Q - How can I trash this file permanently?

    First just try logging out and back in.  Whatever is holding on to it may not be running after the logout thus freeing it so you can trash it after logging back in.
    You might also try Trash It!
    Lastly, look at the following for suggestions:
    The X Lab: Solving Trash Problems

  • When I try to download Firefox for Windows, it unzips the file and says it cannot find 7-Zip file and stops download

    I have windows 7 on a desktop. I had firefox before which worked fine then I attached a router to my computer that may have been defective and may have damaged the computer. I took the router off. Firefox suddenly reverted back to the start up page of when you are new to firefox, e.g. here's how it works, and stopped loading my normal home page. Even though I entered the tabs I wanted for my startup home page every time I shut down my computer it went back to the beginning thinking I had only just loaded it. I did lots of system diagnostics but nothing appeared to be wrong with my computer so I uninstalled Firefox, restarted, then downloaded it again. When I download it, it says run or save and I choose run. Then it extracts the file and a message comes up that says "7-Zip. Cannot find file. Then nothing more happens. No files are downloaded to my computer and it's as though I never tried to download it.

    SAVE the installer to your hard drive (do not use the "Run" option); save it to your Desktop so that you can find it. When the download is complete, close whatever browser you have open, click or double-click the file you downloaded and see if it installs without a problem.
    The downloader is a self-extracting archive and should not need or use 7-zip. I have 7-zip installed on my system and it does not interfere with nor is it used in the Firefox install process. Hopefully, you have not set the downloading of .exe files to be associated with 7-zip.
    '''If this reply solves your problem, please click "Solved It" next to this reply when <u>signed-in</u> to the forum.'''

Maybe you are looking for

  • Convert pdf files to word on line- errors when saving converted file

    every time i hit the save button after exporting a pdf file and converting to word on line there is an error and windows explorer stops responding. what am i doing wrong? is there a problem with the web page, is it dodgey or ???

  • Bedside mode not working

    Hi, Multiple times now I have been woken up by notifications on my phone. This is even though it is in bedside mode when I go to bed.

  • I cannot copy/paste in CS3

    Pretty basic functionality we're talking about here. I also cannot copy back and forth between Ps and Ai. Am I missing some "cool new feature"? I already tried trashing the prefs.

  • Unable to open a new window.

    If I press ctrl + n nothing happens. If I go file > new window nothing happens When i try to open a page that needs to open in a new window nothing happens

  • Patch

    Dear colleague: I installed Solaris 118855-33 on August 8. I can upgrade through Sun update manager. But when I tried to patchadd 118855-36, I got signature invalid/signature failed errors. Do I have to have a service contract in order to upgrade my