PHPFixing
  • Privacy Policy
  • TOS
  • Ask Question
  • Contact Us
  • Home
  • PHP
  • Programming
  • SQL Injection
  • Web3.0

Thursday, August 4, 2022

[FIXED] How can I handle exception in Azure Logic App

 August 04, 2022     azure, azure-iot-suite, azure-logic-apps, exception     No comments   

Issue

I'm using Azure Logic App. This is the architecture:

Insert Row

I have a Scope Insert Row that include an insert statement in database. I would like to send via mail the message of the exception of the insertion. For example if the Insert statement failed with Foreign key exception, i would like to send this message.

How can I refer to this error message inside the 'Send error Msg' feature?

Thanks a lot guys :)


Solution

You could set the Configure run after value to implement it. Set the Send an email action run after Insert row has failed.

enter image description here

enter image description here

If the Insert action success, the send mail won't execute and if it fails the send mail would work. You could also add the run after action value like the time out or is skipped, they are all kind of exceptions.

enter image description here

enter image description here

UPDATE: If this is your error message, you could add it with @{body('Insert_row')?['message']} in code view mode.

And here is my error message and the subject setting.

enter image description here

enter image description here

enter image description here

enter image description here



Answered By - George Chen
Answer Checked By - David Goodson (PHPFixing Volunteer)
  • Share This:  
  •  Facebook
  •  Twitter
  •  Stumble
  •  Digg
Newer Post Older Post Home

0 Comments:

Post a Comment

Note: Only a member of this blog may post a comment.

Total Pageviews

Featured Post

Why Learn PHP Programming

Why Learn PHP Programming A widely-used open source scripting language PHP is one of the most popular programming languages in the world. It...

Subscribe To

Posts
Atom
Posts
Comments
Atom
Comments

Copyright © PHPFixing