How to catch errors from sql adapter?

Home Page Forums BizTalk 2004 – BizTalk 2010 How to catch errors from sql adapter?

Viewing 1 reply thread
  • Author
    Posts
    • #12750

      Hi!,

      I’m working with de Biztalk sql adapter and I’m having problems
      to catch exceptions.

      I’ve tried catching a SOAPException, but nothing occurs.
      Maybe I’m missing something.

      In my orchestration I receive a message, I call an sp (In the sp I insert a duplicate key so an error occurs), finally, in a catch block, I have an expression shape with the following code:

      [code:1:70b662f911]System.Diagnostics.EventLog.WriteEntry(\"SQL\", \"Se produjo un error en SQL Server\", System.Diagnostics.EventLogEntryType.Error); [/code:1:70b662f911]

      But my orchestration doesn’t log that error in the event viewer.

      I have installed SP1.

      Can you help me, please? 😀

      Saludos. Mauricio.

      Buenos Aires – Argentina

    • #12751

      thanks, I’m going to try with your advices.

      Saludos. Mauricio

      • #12752

        You might want to take a look at this lab: http://www.biztalkgurus.com/Labs/Sharepoint-Infopath-BizTalk-Exceptions.html

        I walk though catching and processing the SOAP Exception.

        Not sure, but you might only get the error back if you have Delivery Notification enabled on the Send Port.

        • #12753

          Are you using a request/response port or a one-way send port?

          If one-way – it is async, and the orch continues without error checking (the only way to catch error is by using an secondary transport protocol and writing the message to a file).

          So if you want to catch SOAP-Exception for SQL in an orch – you MUST do a request/response port. This also implies that your Stored Proc return something, if only a \”Success\” or \”Failure\” flag.

          Neal Walters
          http://Biztalk-Training.com

Viewing 1 reply thread
  • The forum ‘BizTalk 2004 – BizTalk 2010’ is closed to new topics and replies.