Skip to content

Knowledge Base

Business Process Automation Platform

Building a Microsoft SQL database triggered HTML email alert

This example task runs based on a change in data in a business system, it queries the database of a business system, formats the information returned as an html email message and sends this to users derived from the information in the business system.

Database-triggered-html-email-alert-task

This task is made up of 4 steps.

Step Named Tool What it does
Change in data detection Microsoft SQL Server Trigger Detects a specific change in data in a business systems database. This step outputs key pieces of information about the change and outputs them as variables.

Setting up a Microsoft SQL Server Trigger Step

Get more information Database Query (ODBC) Reads the database of the business system to find additional details to include in the alert. This step consumes the variables from the previous step and outputs a recordset of data.A recordset is like a table of data.

Querying a database

Format as HTML Format as HTML Takes the recordset results from the previous step and presents them for use in the email. The output from this step is a document set.Each row in the recordset creates a document.

Formatting as HTML

Send Email Send Email (SMTP) Sends an email containing the formatted information. Each document in the document set is sent to a different email address.The email address originates in the recordset.

Sending an email

To read about designing other tasks see

Task Design