Processing Binary files with Mapping NOT (always) possible ??

Hello All,
I need your help solving this strange behaviour of XI.
I am developing a (image)file to (image)file interface with a simple mapping but XI is giving unpredictable results.
Processing the same inputfile e.g. 10 times after each other: results in 6 times OK and 4 times errormessage in SXMB_MONI. After restarting the 4 errormessages sometimes 1 or 2 msg are suddenly processed fine ??!!
The given error is always: "Parsing an empty source. Root element expected!". But why are the
other 6 messages are processed OK ? Why not all the 10 messages returns with error ??
My scenario is :
1) File FTP Sender: pick up image-files (.gif) from FTP-server (30.000 per day)
2) XI mapping: A) via Java program convert file into Base64, otherwise no mapping is possible at all
B) via UDF fill few outputfields only using the inputfilename. There is no need to go "inside" the
inputfile; just get the filename using Dynamic Configuration.
3) File FTP Sender: After message processing store the inputfile on the SAP filer in a particular
directory derived from the filename. Creating the directory and moving the file is done by an OS script in the sender file adapter.
4) XI Receiver HTTP: after succesfull processing the payload is filled with the correct fields.
The cause of error is (sometimes) using the DynamicConfiguration in the UDF, but a few fields must be filled using the inputfilename.
Has someone experienced this before or an other solution/idea to make this scenario stable and robust ??
Regards,
Jack

Jack,
I may not have understood your scenario in full, however, an alternate solution could be to write a custom XI module and attach it to the file adapter. You could access the file name inside the module as well(See SAP Note 819761).
You should get a lot of articles/blogs in SDN on custom XI module creation and deployment to the server via NWDS. Give a thought on these lines as well.
Are you using any third party APIs to base64 encode your files, If so i beleive you will have to include them in the librarries in NWDS and deploy them to the XI server.
Thanks
Saravana

Similar Messages

  • Binary file with File adapter

    Hi gurus,
    I am getting binary file as base64binary (not a text/xml file) in a request XML tag. I need to write this file to a file directory with the file adapter after retrieving it from the request message by a message/java mapping and use another field in XML as the file name.
    I followed the blog `how to send binary data through PI` but in that case, the request message is also the same. Mine requires a mapping to be executed and in this case I cannot use dummy names for message types/interfaces as Enterprise Repository development is required.
    How can I achieve this?
    Thanks
    Gokhan

    Just solved the problem actually
    As I was trying to write a binary file directly with the receiver file adapter, I wasn't sure how to define a data type / message type for it. I developed a java mapping that decodes the base64 to binary data and writes it to the output stream, and used a dummy message type / data type for the service interface as the target in Operation Mapping
    And it worked!
    Regards,
    Gökhan

  • I have written a binary file with a specific header format in LABVIEW 8.6 and tried to Read the same Data File, Using LABVIEW 7.1.Here i Found some difficulty.Is there any way to Read the Data File(of LABVIEW 8.6), Using LABVIEW 7.1?

    I have written a binary file with a specific header format in LABVIEW 8.6 and tried  to Read the same Data File, Using LABVIEW 7.1.Here i Found some difficulty.Is there any way to Read the Data File(of LABVIEW 8.6), Using LABVIEW 7.1?

    I can think of two possible stumbling blocks:
    What are your 8.6 options for "byte order" and "prepend array or string size"?
    Overall, many file IO functions have changed with LabVIEW 8.0, so there might not be an exact 1:1 code conversion. You might need to make some modifications. For example, in 7.1, you should use "write file", the "binary file VIs" are special purpose (I16 or SGL). What is your data type?
    LabVIEW Champion . Do more with less code and in less time .

  • Trying to create a Photomerge in Bridge, when the files open in Photoshop ( small jegs ) , I get a error message of " Unable to process latte files " / " null is not an object "

    Trying to create a Photomerge in Bridge, when the files open in Photoshop ( small jegs ) , I get a error message of " Unable to process latte files " / " null is not an object "
    Please help

    Wait a second, Photoshop can make lattes now?  Personally I prefer my coffee black, but man have I been under-utilizing this program.

  • How to process a file with out any CSV, Delimitaor, fixed length or Copybok

    Hi Team,
    i need to process below file in OSB and need to send mails to the concerns ids...
    this file will have either 1 mail or multiple mails.
    sample.txt file with 1 mail content
    ======================================
    START
    [email protected]
    [email protected], [email protected],
    END
    Subject : CAL IND Renege #00424523 Hse580 CTH580
    BODY:
    User_ID: LARRY014
    XXX Hse/Customer # : 580/1196310
    X12 Order Number: 580094624
    Customer E-Mail: [email protected]
    Customer E-Mail 2: [email protected]
    Customer Phone : 909312345
    Dear Salesperson,
    mysupply.com Order # : 00424523
    mysupply.com User ID : LARRY014
    Customer CALIFORNIA STEEL IND has entered order 00424523
    through mysupply.com.
    THIS ORDER HAS RENEGED for the following reason(S):
    I. ORDER LEVEL
    NOTE SEGMENTS FOUND IN INPUT - SENTRY
    CDF REQUIRED CUSTOMER - ORDER RENEGED
    II. ITEM/LINE LEVEL
    LINE # ECOM LINE NAED QTY STATUS ALLOW SUBS
    Please resolve the renege and release the order in Sentry
    01 as soon as possible. Thank you.
    EMAIL-END
    ====================================
    Please help me ,how to process this file and send mail to the concern people, as its do not have neither CSV, nor Fixed lengthn or its not Cobol copybook nor its not DTD to convert it.
    Thanks
    Reddy
    Edited by: KiranReddy on Feb 3, 2012 9:52 PM

    you shouldn't need a csv if you want a fixed file you need some thing like
    read:
    <xsd:element name="C1" type="xsd:string" nxsd:style="fixedLength" nxsd:length="1" nxsd:paddedBy=" " nxsd:padStyle="tail" />
    <xsd:element name="C2" type="xsd:string" nxsd:style="fixedLength" nxsd:length="xx" nxsd:paddedBy=" " nxsd:padStyle="tail" />
    write:
    <xsd:element name="C1" type="xsd:string" nxsd:style="fixedLength" nxsd:length="1" nxsd:paddedBy=" " nxsd:padStyle="tail" />
    <xsd:element name="C2" type="xsd:string" nxsd:style="fixedLength" nxsd:length="xx" nxsd:paddedBy=" " nxsd:padStyle="tail" />
    <xsd:element name="C3" type="xsd:string" nxsd:style="fixedLength" nxsd:length="5" nxsd:paddedBy=" " nxsd:padStyle="tail" />xx stands for the length of your line
    hope this makes sense
    cheers
    James

  • Issue in reading a binary file, with 'Flatten to String' data.

    I'm facing issue while reading a binary file (created using LabVIEW).
    I've mentioned everything (issue and method to reproduce it) within the attached VI.
    Same vi is attached in 2012 and 8.0 versions.
    Regards
    I am not allergic to Kudos, in fact I love Kudos.
     Make your LabVIEW experience more CONVENIENT.
    Solved!
    Go to Solution.
    Attachments:
    Issue in VI.vi ‏26 KB
    Issue in VI (Version 8.0).vi ‏43 KB

    moderator1983 wrote:
    crossrulz wrote:
    The reading of a string from a binary file stops at a NULL character (0x00).  When the first character is 0x00, you are just reading the one character.  I would suggest writing to a byte array since you are doing the inverting.  And then you can read as a byte array.
    crossrulz:
    U rocks..!!
    you have hit bull's eye...!!
    After playing around a little more, I think I might have misinformed you a little.  If you explicitly tell it a string, it looks for the string length at the very beginning and reads that length of bytes as a string.  It appears that if you implicitly tell it to read a string (not wire the data type) it reads all of the bytes directly, including the length of string you wrote.
    Regardless, my advice is the same.  You should just write and read using byte array.  It is less conversions if you are performing your "encryption".
    EDIT:  Here's a snippet of the VI I was playing with to figure this out.
    There are only two ways to tell somebody thanks: Kudos and Marked Solutions
    Unofficial Forum Rules and Guidelines
    Attachments:
    String Binary File.png ‏12 KB

  • Problem processing multiple files with dll

    I'm using a function in a dll that turns a binary data file into a TSV file with actual numbers.  The function takes three inputs, a pointer to a string for the input file path, a pointer to a string for the file to write and an integer for "integrity check" which as far as I can tell does nothing.  I have the dll in a subvi, pass it a string corresponding to the input file path and let it convert the file.  This works but will only convert the first 254 files then errors out.   The only way I can get it to work again is to close labview completely and reopen it.  My experiment requires the conversion of literally thousands of files so closing and reopening labview gets old real quick.  I have tried creating a reference to the subvi and closing it for each file but this still does not work, I have also tried on windows xp and windows 7.  When the new files are created they have a size of 0 kB and are empty until I close labview then they assume a reasonable size (few kB) and have data in them.  Additionally if I try to delete one of the newly created files while labview is open I get an error saying the file is open in labview.  I can delete the files when labview is closed.  I have also tried opening each file and closing it after the conversion but that does not work either.
    I believe this is some sort of file open limitation but I don't know how to get around it, I'm almost to the point of writing one of those mouse move/button click macros nerds use for games to convert the files because this is driving me insane.

    I managed to get the c code for the dll (it was somewhere on the computer). I can only pass an integer to validity otherwise it errors, is there an unsighed char in labview?
    _declspec (dllexport) int converting(char *filetoRead, char *filetoWrite, unsighed char validity)
    FILE *fpin, *fpout;
    int result;
    int records=0;
    int valid=0;
    unsigned long MTOFL=0;
    unsigned long MT;
    struct {unsigned ADC:12;
    unsigned INVALID
    unsigned MTOV:1;
    unsigned GAP:1;
    unsigned ZERO:1;
    unsigned MTHIGH:
    unsigned R:8;
    unsigned MTLOW:
    } DataRecord;
    fpin=fopen(filetoRead,"rb");
    fpout=fopen(filetoWrite,"w");
    while(1)
    result = fread( &DataRecord,
    if (result!= 6)
    return(0);
    records++;
    if(DataRecord.MTOV)
    MTOFL += (unsign
    if(validity==1)
    if(DataRecord.INVA
    continue; // don't sav
    valid++;
    MT = (((unsigned long)Data
    fprintf(fpout,"%11lu",MTOF
    fprintf(fpout,"%5u",DataRec
    fprintf(fpout,"%4u",DataRec
    fprintf(fpout,"%6u",DataRec
    fprintf(fpout,"\n");
    fclose(fpin);
    fclose(fpout);
    return 0;

  • How to get rid of a binary file with firefox that pop up allthe time?

    each time that i open moxilla firefox a box asking if I want to save or cancel the binary file. I have tried to ignore ti however it has become a bother. How do I stop the box from popping up ?

    Hi
    if you mean http://db.tidbits.com/ - I didn't get any popups in a few minutes of browsing there, this without any blocking software. If you're seeing the very same ad popup window from differing sites, then it'd sure be worth looking at whether or not your mac or router or isp is using some rogue dns server.
    DNS - Domain Name System
    it translates domain names meaningful to humans into the numerical (binary) identifiers associated with networking equipment for the purpose of locating and addressing these devices worldwide. An often-used analogy to explain the Domain Name System is that it serves as the "phone book" for the Internet by translating human-friendly computer hostnames into IP addresses. For example, www.example.com translates to 192.0.32.10.
    to borrow from wiki.
    DNS servers can be chosen in your router or in your mac at System Preferences-Network-Advanced-DNS tab, If no special dns servers are selected, your router will usually accept the isp's suggestion, so you'll be using theirs, for better or for worse.
    The most common place for any 'rogue' dns to be set, is in System Preferences-Network-Advanced-DNS tab... look there on your mac, and see if any numbers are visible. Copy them & paste here, then we'll know what's going on.

  • Optimal workflow for batch processing LR files with Nik plug ins

    I have a series of 40 or so landscape images that I would like to efficiently apply a couple of Nik filters to using Color Efex.  I'd appreciate any suggestions re: the most efficient workflow to accomplish this task in a batch processing approach, as my current approach of taking each image into Photoshop, while preserving Smart Filter benefits, is terribly inefficient.  Thanks in advance.

    Hi,
    Sorry but File->Process Multiple Files is the only way and functionalities with which you can batch process your images in PSE. However you can add action in Window->Action Player and apply to your images opened in workspace -
    http://tv.adobe.com/watch/learn-photoshop-elements-11/adding-actions/
    http://forums.adobe.com/message/4736578
    The functionality is available in full functionality product Photoshop via File->Automate->Batch where you can load actions in action panel and they would appear in this dialog box but this is not available in Elements.
    The best way to do here is to load actions in Window->Action Player and open all your images and click on play button one by one and then use Process Multiple Files to save all these in one go as per your preferences of file type, size, name etc.
    Thanks,
    Garry

  • Processing raw files with Elements 8

    I have Elements 8 for the processing the raw files from my Nikon D40.  There has been not issue with these files.  I just recently picked up a D7100.  Now with this camera when i download the raw files to the computer I am receiving a message that Elements does not reconize those raw files and will not open them. 
    Is there some different setting for the newer camera's?

    Every camera has its own raw format and the raw converter must be updated to work with each new camera model. PSE 8 will not open those files--it's just too old to be able to be updated far enough.
    Your options are:
    1. Upgrade to PSE 12.
    2. Use the nikon software to convert the files and just use PSE for further editing for the converted files.
    3. Download the free Adobe DNG converter to make DNG files from your NEFs. PSE 8's raw converter can read those.

  • Upload binary files with Developer Forms

    Hi all,
    I'm newbie with Forms and I don't know if this question is already answered.
    I'm deploying an application involved with blob columns (binary files: pdf, doc, gif, etc) I want to let users to choose files from his PCs (typical "Browse files" button) but I don´t know if this is possible and if yes, how to implement it.
    Anybody can help me?
    My email is [email protected]
    Thanks in advance!
    Cristina

    If you want to upload direct into the database from the client then No you will need a 9i database or above.
    If you want to upload a file from the browser client to the middle tier (Application server) then that will be OK no matter what DB version you are using. Bug of course you'll then need to do the last bit yourself if you want the document / image put into the database.

  • Opening a binary file with the right extension

    Hi everyone,
    I developed a real simple VI that enables me to read the first five bytes of a binary file to get its signature (ASCII) and verify if its signature matches with the expected extensions. If yes, another VI is called, and if not a 2 button message error is displayed : if the User chooses OK, then a new dialog box opens up to pick another file ; and if the user chooses Cancel, the same dialog box opens up rather than escaping the VI.
    It is due to the while loop (VI below) but i don't see how I can handle this without it. Till the user hasn't chosen the right extension, it can't escape which is a problem! The true case consists in calling another VI, and the first step of the stacked sequence consists in displaying a two button error message.
    If you have any ideas, I'm a bit new! Thanks !!
    Solved!
    Go to Solution.

    Thanks for your replies!
    I have tried your solution CoqRouge, filtering the extensions. But it seems that you can choose between different filters when the dialog box opens up, and then choose any kind of extensions.
    @RavensFan : I cannot load the VIs attached in this thread because I am using an older version of Labview
    @MikeS81 : Which negative ouput?
    Attachments:
    ptw_show_do_while.vi ‏20 KB

  • Address Book sync with lotus Notes is possible

    Hi,
    I'd like to know if it is possible to sync Personal Address book with lotus notes?
    Or there are Ip phone services that can query address book of lotus notes?
    Regards
    MC

    I developed an application for a German customer who is using Lotus Domino too.This application should be accesed through Services button on IP Phone This application queries Domino directory or Notes Personal Address Book via WebServices and displays results on IP phone. You can find a User Manual in german on my website http://www.arsnet.eu/workshop/iBOS20-Cisco-DE-pptA4.pdf . I can develop this Application in English too.
    Regards, Robert

  • Exception thrown while processing pdf file with composite fonts using adobe pdf library (v 9.1 )

    Hi All,
    I have an issue with processing composite fonts with adobe pdf library (v 9.1 ).
    While processing a pdf file having composite fonts, the pdf library is throwing an exception.
    The api which throwed exception is "PDPageAcquirePDEContent()". In my code i am calling PDDocGetNumPages(), PDDocAcquirePage() before this api is called, but all those functions suceeded. In the HANDLER, using the ASGetErrorString(), i got this exception error as  "The encoding (CMap) specified by a font is missing."
    Now coming to the input file (which is also attached), this document have three different composite fonts ( details are given below )
    Font Name : TicketBold, Bold(Embedded)
    Font Type : Trueype (CID)
    Encoding : Identity-H
    Font Name : Times-Roman (Embedded)
    Font Type : Type 1 (CID)
    Encoding : Identity-H
    Font Name : TimesNewRomanPSMT (embedded)
    Font Type : TrueType(CID)
    Encoding: Identity-H
    If i convert all the composite fonts to outline using pitstop before processing, it works fine.
    So my question is that whether pdf library doesnt support composite fonts (which i dont think so ) or i need to do a special handling for these kinds of fonts in my application ( which i strongly belive ). If its the latter case, please let me know how to handle it in my application.
    thanks in advance
    best regards
    ~jafeel

    Hi Leonard,
    Thanks for your reply. May i ask you which sample of the PDF Library you used to test my scenario.
    One question i would like to put to you beofre going for filing a formal issue to Adobe will be does this issue has anything to do with the initialization of the pdf library?
    What i meant is that when we call the PDFLInit() we pass a PDFLDataRec structure which is initialized by various path to font folders, cmap folders and unicode folders. Whether if i miss any of these folders will it cause this issue???
    thanks again
    regards
    ~jafeel

  • Can't decrypt binary file with PBE

    Hi,
    I'm writing an simple file transfer application using UDP that encrypts the data
    before sending it with PBEWithMD5AndDES. Text files are encrypted and
    decrypted fine, but binary files such as a JPG/EXE/DOC... are messed up
    and an application can't open them on the other side. Has anyone experienced
    such a problem?
    Thanks

    Below are my encrypt and decrypt functions.
    Thanks in advance.
            public  byte[] encrypt(byte[] data)
                 PBEKeySpec pbeKeySpec;
                 PBEParameterSpec pbeParamSpec;
                 SecretKeyFactory keyFac;
                 ByteArrayOutputStream b=null;
                 DataOutputStream d =null;
                 //      Salt
                 byte[] salt = {
                           (byte)0xc7, (byte)0x73, (byte)0x21, (byte)0x8c,
                        (byte)0x7e, (byte)0xc8, (byte)0xee, (byte)0x99
                 //      Iteration count
                 int count = 1000;
                 // Create PBE parameter set
                 pbeParamSpec = new PBEParameterSpec(salt, count);
                 try{
                      pbeKeySpec = new PBEKeySpec(sessionPassword.toCharArray());
                      keyFac = SecretKeyFactory.getInstance("PBEWithMD5AndDES","SunJCE");
                      SecretKey pbeKey = keyFac.generateSecret(pbeKeySpec);
                      // Create PBE Cipher
                      Cipher pbeCipher = Cipher.getInstance("PBEWithMD5AndDES","SunJCE");
                      // Initialize PBE Cipher with key and parameters
                      pbeCipher.init(Cipher.ENCRYPT_MODE, pbeKey, pbeParamSpec);
                      b = new ByteArrayOutputStream();
                      d = new DataOutputStream(b);
                      // create CipherOutputStream
                      CipherOutputStream out = new CipherOutputStream( b, pbeCipher );
                      // write contents to file and close
                      try {
                           for ( int i = 0; i < data.length; i++ )
                                out.write(data);
                             out.flush();
                        out.close();
                   // handle IOException
                   catch ( IOException exception ) {
                        exception.printStackTrace();
              catch(Exception e){}
              return(b.toByteArray());
         public byte[] decrypt(byte[] data)
              PBEKeySpec pbeKeySpec;
              PBEParameterSpec pbeParamSpec;
              SecretKeyFactory keyFac;
              byte[] decryptedData=null;
              //      Salt
              byte[] salt = {
                        (byte)0xc7, (byte)0x73, (byte)0x21, (byte)0x8c,
                        (byte)0x7e, (byte)0xc8, (byte)0xee, (byte)0x99
              //      Iteration count
              int count = 1000;
              // Create PBE parameter set
              pbeParamSpec = new PBEParameterSpec(salt, count);
              try{
                   pbeKeySpec = new PBEKeySpec(sessionPassword.toCharArray());
                   keyFac = SecretKeyFactory.getInstance("PBEWithMD5AndDES","SunJCE");
                   SecretKey pbeKey = keyFac.generateSecret(pbeKeySpec);
                   // Create PBE Cipher
                   Cipher pbeCipher = Cipher.getInstance("PBEWithMD5AndDES","SunJCE");
                   // Initialize PBE Cipher with key and parameters
                   pbeCipher.init(Cipher.DECRYPT_MODE, pbeKey, pbeParamSpec);
                   Vector fileBytes = new Vector();
                   ByteArrayInputStream b = new ByteArrayInputStream(data);
                   CipherInputStream in = new CipherInputStream( b, pbeCipher );
                   byte contents = ( byte ) in.read();
                   while ( contents != -1 )
                        fileBytes.add( new Byte( contents ) );
                        contents = ( byte ) in.read();
                   in.close();
                   decryptedData = new byte[ fileBytes.size() ];
                   for ( int i = 0; i < fileBytes.size(); i++ )
                        decryptedData[ i ] = (( Byte )fileBytes.elementAt( i )).byteValue();
              catch(Exception e){Gui.chatArea.append("exception:"+e+"\n");}
              return(decryptedData);

Maybe you are looking for

  • Rebooting when turning off and percentage problems

    i have downloaded 3.1.3 and since then when i turn my iphone on in the morning my percentage will show the wrong amount, then when i unlock it a second later it will jump to the right percentage, an example is this morning i knew it was at about 45%

  • Commitment Item in Project System

    Hi, How could i create commitment item in project system without creating a PO for a project. Please advice.

  • How  restet field-content selection-screen when I return to screen 1

    Hi! My case! 0) Abap report pgm with selection-screen fields. 1) I have a screen where the user send in information in    X fields. 2) The content is shown as an ALV list. 3) Table will be updated. 4) Return to first screen where screen-output has be

  • Redirecting a domain URL to a file

    Is there any SAF directive (e.g NameTrans) to redirect a domain URL (e.g http://www.xyz.com/rob.txt) to a file rob.txt sitting at location /x/y/rob.txt (other than root directory rob.txt). Bascially I want to achieve any request coming to http://www.

  • I can't download games

    When I try to download a new game it says it can't connect to a secure network. It connect to my house network no problem for everything else. I can  search games but when I try to download any game it won't let me. Our home network is not password p