Accesing message context in map RRS feed

  • Question

  • Hi,

    I have a map that will be executed on a send port. This send port will persist data in sql table. I am trying to access message context value of the input message in this map so that it can persisted in the table. I am tring to do this using scripting functoid as shown in the screen shot. When this map is executed at run time I am seeing an error 

    The Messaging Engine failed while executing the outbound map for the message going to the destination URL "mssql://.//MyDBName/?" with the Message Type "ValidMessageType". Details:"Exception has been thrown by the target of an invocation." Is there a way this error can be resolved. 

    Thursday, June 20, 2019 3:11 PM

All replies

  • So, that's not at all what that method does.  Thus, there is no way to resolve this specific error.

    If you describe exactly what you're trying to do, we can give you some guidance.

    99%, it will to be access and set the property in an Orchestration.  There is nothing wrong with using Orchestrations.

    Thursday, June 20, 2019 3:37 PM
  • In addition to the first paragraph in my original post, we are trying to persist message type in a separate column in the table. I am trying to see if this can be achieved by using the assemblies that are already referenced in the project that contains this map. Agree with nothing wrong with using orchestration but if we can achieve this using map and send port alone there would be one less artifact to manage. Beyond that just want to know if anyone has managed to do what I am trying to do using messaging solution.
    Thursday, June 20, 2019 4:05 PM
  • Then you probably can use the Property Demotion feature of the XmlAssembler in stead of a Map.

    Property Demotion in Assembler Pipeline Components

    Basically Promotion in reverse.

    Thursday, June 20, 2019 6:01 PM
  • My take from your reply is I can't use the external assembly Microsoft.BizTalk.GlobalPropertySchemas to get hold of messagetype of the incoming message. Is that accurate ?
    Thursday, June 20, 2019 8:56 PM
  • >> that's not at all what that method does.


    Thursday, June 20, 2019 9:08 PM