To add up so we can help someone else...

This is what I really needed for this to work

Set reader = ##class(%XML.Reader).%New()
    Set status = reader.OpenString(messagedata)

    Do reader.Rewind()

    If $$$ISERR(status) {do $System.Status.DisplayError(status)}
    
    // Associate a class name with the XML element name
    Do reader.Correlate("MIU","Message.Request")
 

<Oceano>
    <Header>
        <DataSource>Oceano</DataSource>
        <DataType>EDAttendance</DataType>
    </Header>
    <Body>
        <MIU>
            <Department>BCH</Department>
            <TotalNumber>6</TotalNumber>
            <NumberWaitingToBeSeen/>
            <LongestWaitMin/>
        </MIU>
        <MIU>
            <Department>BOS</Department>
            <TotalNumber>1</TotalNumber>
            <NumberWaitingToBeSeen>1</NumberWaitingToBeSeen>
            <LongestWaitMin>109293</LongestWaitMin>
        </MIU>
    </Body>
</Oceano>

Hope this helps

Hi guys

I'm trying something similar to this. I am call a bpl from another bpl.

When I do a trace for a context variable in the second bpl it shows up as empty.

I've also set the context super class in the 2nd bpl to be the context of the first one. I can see the context properties in the 2nd one in settings but they don't seem to be passed over.

How can I get the context of the main bpl?

Hope this makes sense...

Regards

Hi

In our case the ID for the Message is in the field MessageControl ID

if we replace ID with Identifier, which holds the MessageControl ID, the Query bellow does not work...

&sql(
            SELECT RawContent INTO :HL7RawContent
            FROM EnsLib_HL7.Message
            WHERE ID=:pID           
        )

Anyone have an Idea why and how to work around this?

The "Identifier" column exists in EnsLib_HL7.Message...

Thank you

May I just  ask you another Question Sean?

We've got everything working. The only issue is that the operation partner which sends the original message out is dealing with the application ACKs (because it is the Partner). Our endpoint guys say they are getting a second message. Therefore, the original the ADT message and the ACK which the endpoint application don't want...

Is that because of the Reply Code Actions? I'm sorry if that's a dumb question. I am quite new to Ensemble and we don't learn everything at the Training...

Kind Regards,

Joao Palma