none
Get UNB information in orchestration RRS feed

  • Question

  • Hi 

    How can I get the information of the UNB Segment in a orchestration? I need this to create the filename Sender_receiver_UNB_ID.txt

    Regards


    Klaus 
    Klaus Weber
    Wednesday, January 14, 2009 10:14 PM

Answers

  • You will need to either go into the schema and promote what you want, either as a promotion or as a dist. field or you can XPath it out
    outmsg(File.ReceivedFilename)=(string)xpath(inmsg,"\xpath\text()")+".txt"
    • Marked as answer by KWeber Thursday, January 15, 2009 5:20 PM
    Wednesday, January 14, 2009 10:37 PM

All replies

  • You will need to either go into the schema and promote what you want, either as a promotion or as a dist. field or you can XPath it out
    outmsg(File.ReceivedFilename)=(string)xpath(inmsg,"\xpath\text()")+".txt"
    • Marked as answer by KWeber Thursday, January 15, 2009 5:20 PM
    Wednesday, January 14, 2009 10:37 PM
  • Hi,
        If you want to create the file name Sender_receiver_UNB_ID.txt . Then you can use a pipeline component with a Dynamic send port. In the Pipeline Component you can read the UNB ID and you can make the file name as UNB ID. And by choosing your Pipeline component in the dynamic send port you can create the filename Sender_receiver_UNB_ID.txt.



    Thanks
    Gyan
    Thursday, January 15, 2009 11:53 AM
  • Hi Gyan


    Do have an example for this pipeline component?

    Regards
    Klaus Weber
    Thursday, January 15, 2009 1:44 PM
  • By far the easiest way to do it is to use the orchestration to assign the Received File Name to the outgoing msg, and then in the send port put the following macro in the port
    \\server\folder\%SourceFileName%

    This requires no custom coding.
    You can write a custom pipeline component that will do the same thing, but it is litterally one line of code in the orchestration.
    Thursday, January 15, 2009 3:27 PM
  • Hi Eric


    You are right. I only was interested in this pipeline solution. Thanks for your help

    regards


    Klaus Weber
    Thursday, January 15, 2009 5:19 PM
  • So are you still interested in the pipeline solution?
    Thursday, January 15, 2009 5:21 PM
  • Hi Eric

    Yes I am still interested. Perhaps someone could give me a description how to create it

    Thanks 
    Klaus Weber
    Wednesday, January 21, 2009 8:05 AM