none
BizTalk 2010 997 : Message Type 997 is not allowed as part of the Agreement. RRS feed

  • Question

  • Hi,

    Running BizTalk 2010,  Trying to process a 997 Ack, that is automatically generated in BTS 2010. If the send port that is subscribing to the auto generated 997 is using the passthrough pipeline, the below message is delivered with no errors:

    <ns0:X12_997_Root IsGeneratedAck="true" xmlns:ns0="http://schemas.microsoft.com/Edi/X12">
      <ns0:ST>
        <ST01>997</ST01>
        <ST02>0014</ST02>
      </ns0:ST>
      <AK1>
        <AK101>IN</AK101>
        <AK102>5082</AK102>
      </AK1>
      <AK9>
        <AK901>A</AK901>
        <AK902>1</AK902>
        <AK903>1</AK903>
        <AK904>1</AK904>
      </AK9>
      <ns0:SE>
        <SE01>4</SE01>
        <SE02>0014</SE02>
      </ns0:SE>
    </ns0:X12_997_Root> 

     If switch the pipeline in the send port to the EDISend Pipeline get the below error:

    A message sent to adapter "FILE" on send port "SndPortEDI997_EDIFor_LAG-DSHE" with URI "C:\DirectSupply\DSE\DSEBTS2004Code\DSE Transaction\Biztalk\MigratedBizTalk2010\Files\Out_X12_997_ForLAG_DSHE\%MessageID%.edi" is suspended.

    Error details: There was a failure executing the send pipeline: "Microsoft.BizTalk.Edi.DefaultPipelines.EdiSend, Microsoft.BizTalk.Edi.EdiPipelines, Version=3.0.1.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" Source: "EDI Assembler" Send Port: "SndPortEDI997_EDIFor_LAG-DSHE" URI: "C:\DirectSupply\DSE\DSEBTS2004Code\DSE Transaction\Biztalk\MigratedBizTalk2010\Files\Out_X12_997_ForLAG_DSHE\%MessageID%.edi" Reason: Message Type 997 is not allowed as part of the Agreement.

    MessageId: {777FB827-AF10-4BF7-BC1F-F733F0828B88}

    InstanceID: {FE482BF4-2C2F-4F2E-9C7A-51E335779D9C}

     As far as I can see, when configuring an agreement, cannot choose a 997 message anywhere, for example , in the Transaction Set List. 

    Does anyone have any ideas?

    Thanks.

     

    Monday, November 1, 2010 2:30 AM

Answers

All replies

  • Freddy,

    When you create the agreement between 2 parties, right click the sender party to create the agreement. First party should be the sender and the second party should be your receiver. I believe you have configured the other way around.

     

     


    Sathish - http://blog.tsathish.com
    Monday, November 1, 2010 2:16 PM
  • Hi Sathish.

    I will give a try, but the message flow goes as below:

    MyCompany is Sending 850's to AnotherCompany and MyCompany expects to Receive back 997's acknowledgements for the 850's.

    AnotherCompany is Sending 810's 855's to MyCompany and AnotherCompany expects to Receive back 997 acknowledgements for the 810's 855's. This is the part where I am having the error as described in the original post.

    Therefore it is a true Two way agreement, ie both entities expecting back 997's with both parties acting as a Sender and Receiver. The BizTalk 2010 documentation seems to support this (ie creating one agreement for the above)?

    Anyways, I will play around with creating the agreement again, but in reverse.

    Monday, November 1, 2010 4:40 PM
  •  

    I set up as suggested above, and the Ack was working, but then I modified the Agreement to to process 850's. And now does not work again.

    (Get same error - Message Type 997 is not allowed as part of the Agreement)

    Microsoft provdied some examples to set up sending messages one way, (ie in the Walkthroughs) as below:

    http://msdn.microsoft.com/en-us/library/bb226324(v=BTS.70).aspx

    But unfortunately,left out an example of processing a complete loop of messages. For example , I cannot find an example or walkthrough for a scenario as below:

    MyCompany sends out 850 to AnotherCompany , expects back a 997

    AnotherCompany Sends back 997's for (850's)

    AnotherCompany  sends out 810's 855's  to MyCompany

    MyCompany  sends out 997 acks for the 810's 855's  to MyCompany

    I can get the processing working one-way (ie Sending Messages from MyCompany  to AnotherCompany  or visa versa) , but as soon as  start modifying the Agreement to process the the other direction, everything stops working.

    Does anybody have an example of a setting up the Parties and Agreement, for a full message flow as above?

    My Abbreviated Agreement Set Up is as below:

    AnotherCompany -> MyCompany

    Configured the above tab for processing 810s, 855's, 997 acks for 810's 855's 

    MyCompany -> AnotherCompany

    Configured the above tab for processing and batching 850's

    From a high level does the above setup look correct?

    Thanks

    Tuesday, November 2, 2010 9:41 PM
  •  

    Freddy,

    I tried to set up a similar scenario as you explained but with different transactions. Find below the sample agreement and Party Setup.

     

    Sender (Another Company ) - Apollo Hospital

    Receiver (My Company) - Best Care Group - (BizTalk is used by My Company).

    Sender - Another Company - Apollo Hospital sends 276, 837P,837I,837D to Best Care Group and expects 997 Acks for all these transactions.

    Receiver - My Company - Best Care Group sends 277 to Apollo Hospital and expects 997 Ack.

     

    Create Party For Receiver - My Company - Best Care Group . Use Default Profile and configure the Identifiers. (I am not using X12 Protocol Settings)

    http://blog.tsathish.com/wp-content/uploads/2010/11/ForFreddy/ReceiverProfile.png

    Create Party For Sender - Another Company - Apollo Hospital . Use Default Profile and configure the Identifiers. (I am not using X12 Protocol Settings)

    http://blog.tsathish.com/wp-content/uploads/2010/11/ForFreddy/SenderProfile.png

    Right Click Sender - Apollo Hospital Profile and select new Agreement

    Make sure the first Party is Sender - Another Company - Apollo Hospital and second party is Receiver - My Company - Best Care Group

    Set Protocol Set for Both the party is None

    http://blog.tsathish.com/wp-content/uploads/2010/11/ForFreddy/Agreement General Properties.png

    Set Sender -> Receiver : Identifier Node

    http://blog.tsathish.com/wp-content/uploads/2010/11/ForFreddy/SenderToReceiver_identifierTab.png

    Set Sender -> Receiver : Acknowledgment Node

    http://blog.tsathish.com/wp-content/uploads/2010/11/ForFreddy/SenderToReceiver_AckTab.png

    Set Sender -> Receiver : Transaction Set List  Node

    Here i have selected 276,837P,837D,837I as set of transactions received by My Company.

    http://blog.tsathish.com/wp-content/uploads/2010/11/ForFreddy/SenderToReceiver_TransactionListTab.png

    Set Receiver -> Sender : Identifier Node

    http://blog.tsathish.com/wp-content/uploads/2010/11/ForFreddy/ReceiverToSender_identfiersTab.png

    Set Receiver -> Sender : Acknowledgment Node

    http://blog.tsathish.com/wp-content/uploads/2010/11/ForFreddy/ReceiverToSender_AckTab.png

    Set Receiver -> Sender : Envelope  Node

    http://blog.tsathish.com/wp-content/uploads/2010/11/ForFreddy/ReceiverToSender_EnvelopeTab.png

    I have set the above list of transactions with single agreement that support both Receive and Send EDI along with 997 Acks.

    Hope this solves your requirement.


     


    Sathish - http://blog.tsathish.com
    • Marked as answer by Freddy King Friday, November 5, 2010 8:38 PM
    Wednesday, November 3, 2010 4:07 AM
  • Hi Sathish,

    Thanks so much for the detailed overview! I did try your set up with AnotherCompany -> MyCompany) set as the first tab in the agreement, but I will try it again and follow your instructions on my set of messages.

    One thing that may be different in my setup, is that I am batching my outgoing 850's . (in your case it would be a 277's). Maybe you are batching your 277's?

     

    My scenario for batching is as follows. A Flat File (non EDI message is submitted into BizTalk).

    1) Flat File is disassembled into XML in Rcv Location.

    2) XML message is published in MessageBox

    3) Orchestration subscribes to XML Message

    4) XML Message is mapped to BizTalk 850 3010 EDI Schema

    5) Before sending the EDI message out , set the following promoted fields.

    msgX12_00301_850(EDI.ToBeBatched) = true;

    msgX12_00301_850(EDI.DestinationPartyName) = "AnotherCompany";

    msgX12_00301_850(EDI.BatchName) = "BatchFor_AnotherCompany";

    6) Direct Send the above message into the Messagebox.

    7) My Batch configured on my Agreement (Tab MyCompany -> AnotherCompany), picks up the message and batched.

    The batching orchestration from the BizTalk documentation, does do some validation on the incoming  messages.

    If I have my agreement set up as:

    MyCompany -> AnotherCompany (First Tab)  /  AnotherCompany -> MyCompany (Second Tab)

    The above seems works

    If I have my Agreement set up as as the reveresed:

    AnotherCompany -> MyCompany (First Tab) / MyCompany -> AnotherCompany (Second Tab)

    The Bathing Orchestration fails with validating the message.

    Therefore my conclusion , what I was thinking was that when doing the batching, the Agreement Setup of

    AnotherCompany -> MyCompany (First Tab) / MyCompany -> AnotherCompany (Second Tab)

    does not work properly.  

    Maybe, I am erroneous of my conclusion.

    Sathish, do you have any thoughts on the above?

    Thanks Again.

     

     

     

     

     

     

     

     

     

     

     

     

     

    Wednesday, November 3, 2010 2:37 PM
  • Freddy,

    I do batch the 277 files. But i am batching everything in my orchestration and send the message to send port which has edisend pipeline.

    I don't use the batching orchestration feature by BizTalk server.

     


    Sathish - http://blog.tsathish.com
    Wednesday, November 3, 2010 2:56 PM
  • Hi Sathish,

    Thanks for the quick response!

    Just curious as to why you do not use the built-in batching ?

    Any hints as to how you do your own custom batching? Are there any considerations when constructing this custom batched message?

    Thanks Again.

    Wednesday, November 3, 2010 3:08 PM
  • Freddy,

    I take information from database to create the 277 files.

    I take all the information for all the batches at one shot from the database and map to 277 schema. Out put from the map will have all the 277 batches and send it to send port to create the file.


    Sathish - http://blog.tsathish.com
    Wednesday, November 3, 2010 3:14 PM
  • Hi Sathish,

    I am assuming that when you are doing this, you have to mimic what the built in batching process does and wrap your transactions in an envelope. Before you send to a send port configured with EDI Send Pipeline? . Something like below:

     <X12InterchangeXml DelimiterSetSerializedData="94:13:10:42:62:-1:-1:-1:-1">
    - <ns0:ISA xmlns:ns0="http://schemas.microsoft.com/Edi/X12ServiceSchema">
      <ISA01>*</ISA01>
      <ISA02>*</ISA02>
      <ISA03>*</ISA03>
      <ISA04>*</ISA04>
      <ISA05>01</ISA05>
      <ISA06>99121597595</ISA06>
      <ISA07>12</ISA07>
      <ISA08>4414296000</ISA08>
      <ISA09>*</ISA09>
      <ISA10>*</ISA10>
      <ISA11>U</ISA11>
      <ISA12>00301</ISA12>
      <ISA13>*</ISA13>
      <ISA14>0</ISA14>
      <ISA15>T</ISA15>
      <ISA16>></ISA16>
      </ns0:ISA>
    - <FunctionalGroup DocType="http://schemas.microsoft.com/BizTalk/EDI/X12/2006/#X12_00301_850">
    - <ns0:GS xmlns:ns0="http://schemas.microsoft.com/Edi/X12ServiceSchema">
      <GS01>PO</GS01>
      <GS02>99121597595</GS02>
      <GS03>4414296000</GS03>
      <GS04>*</GS04>
      <GS05>*</GS05>
      <GS06>*</GS06>
      <GS07>X</GS07>
      <GS08>00301</GS08>
      </ns0:GS>
    - <TransactionSet DocType="http://schemas.microsoft.com/BizTalk/EDI/X12/2006/#X12_00301_850" TransactionSetActivityId="">
    - <ns0:X12_00301_850 xmlns:ns0=http://schemas.microsoft.com/BizTalk/EDI/X12/2006/>
    - <ST>
      <ST01>850</ST01>
      <ST02>1000</ST02>

    etc etc . More Transactions

    - <ns0:GE xmlns:ns0="http://schemas.microsoft.com/Edi/X12ServiceSchema">
      <GE01>2</GE01>
      <GE02>*</GE02>
      </ns0:GE>
      </FunctionalGroup>
    - <ns0:IEA xmlns:ns0="http://schemas.microsoft.com/Edi/X12ServiceSchema">
      <IEA01>1</IEA01>
      <IEA02>*</IEA02>
      </ns0:IEA>
      </X12InterchangeXml>

    Thanks Again.

     

    Wednesday, November 3, 2010 3:40 PM
  • Freddy,

    Create the map to map from source to edi message in the orchestration starting from ST to SE elements. Before sending the message to the send port update the

    send277Msg(EDI.DestinationPartySenderQualifier) = "ISA07 Value";
    send277Msg(EDI.DestinationPartySenderIdentifier) = "ISA08 Value";
    send277Msg(EDI.DestinationPartyReceiverQualifier) = "ISA05 Value";
    send277Msg(EDI.DestinationPartyReceiverIdentifier) = "ISA06 Value";


    Sathish - http://blog.tsathish.com
    Wednesday, November 3, 2010 9:59 PM
  • Hi Sathish,

    So in the end what was causing the error -> Message Type 997 is not allowed as part of the Agreement. Was on my Agreement Config for:

    MyCompany  -> AnotherCompany  agreement tab. I had set:

    Transaction Set List

    SupportTransaction Sets from the list:

    850-Purchase Order

    When I removed this, and the list was empty, then the error went away.

    I had noticed that you did not set anything on your Transaction Set List for -> Best Care Group -> Apollo Hospital Tab.

    BTW

    I did set my Agreement Config as:

    MyCompany  -> AnotherCompany (First Tab)

    AnotherCompany -> MyCompany  (Second Tab)

    Also on the AnotherCompany Part, I unchecked ->

    Local BizTalk Processes messages received by the party or supports sending messages from party.

    With the above set, everything worked as expected.

    Anyways, thanks for all your help!

     

     

    Friday, November 5, 2010 8:38 PM