|
| Thank you very much Matt! I did get things working by mapping from my source
to my multipart message. Only one value mapped from the Source message, so I
used functoids to initialize the other two multipart message values.
(Without initialization, they were throwing XLANG exceptions as they are
distinguished fields). I then used an expression shape downstream to reset
the values based on whether a particular transformation had caught an
exception, and what the exception was. Works well. Unfortunately, most of
the target document validation does NOT happen in the mapping stage, but
later during serialization in the HIPAA EDI adapter. I really do NOT have a
clue how to catch those errors, as the HIPAA EDI adapter cannot be
incorporated into an orchestration. Of course, I can always look in HAT, but
I was looking for better approach from an EAI standpoint. I feel as though I
have built a beautiful dam to stop any potential flooding, just on the WRONG
river! Thanks again for your help.
JT
--
John
"Matt Milner" wrote:
> Sorry if I was unclear, I was typing too fast. 
>
> The part of your message is an schema based part, meaning that it is going
> to contain xml matching your schema. In order to initialize any XML based
> message part, you only have a couple of options, the two that I mentioned,
> plus some other more involved ways that usually are overkill.
>
> Your distinguished properties, which is what it looks like you have with
> your SQL message part, are shortcuts to set XML values. You could
> accomplish the same thing with XPath, but distinguished properties are much
> easier. However, before being able to set some value in the XML document,
> you have to HAVE an xml document. Furthermore, when using distinguished
> properties, you also have to have the existing element/attribute in the
> document before you try to set its value.
>
> So, the simplest way is to use a map if you have an incoming document that
> you can map to this part. You don't have to set a bunch of values in the
> destination, just get the structure there. In addition you could do
> something like the following in your message assignment shape before the
> code you currently have:
>
> varXmlDoc = new System.Xml.XmlDocument();
> varXmlDoc.LoadXml("<rootnodename
> xmlns='yournamespaceForMessagePart'><procBTS_MsgProcReturnStatus TranID=' '
> Status=' ' Msg=' ' /></rootnodename>";
> SQLSendMsg.parameters = varXmlDoc;
>
> //now set the distinguished properties -- note you could have included them
> in the xml above as well
>
>
>
> Hopefully this is a little more clear.
>
> Matt
>
>
>
> "JT" <Jthayer@online.nospam> wrote in message
> news:66B03F77-D503-4C53-8B15-F75083C0BBD0@microsoft.com...
>
>
>
|
|