Practice Lab 7 – Trigger filters

In this lab you will filter on an update trigger.

What you will learn

  • How to filter triggers

High-level lab steps

  • Create an automated flow
  • Add column filter
  • Add query filter

Prerequisites

  • Must have completed Lab 2: Data model

Detailed steps

Exercise 1 - Schema name

Task 1.1 - Column schema name

  1. Navigate to the Power Apps Maker portal https://make.powerapps.com

  2. Make sure you are in the Dev One environment.

  3. In the left navigation pane, select Tables.

  4. Select Opportunity.

  5. Under Schema, select Columns.

  6. Select the Status column.

    Screenshot of status columns.

  7. Expand Advanced options.

    Screenshot of column schema name.

  8. Copy the Logical name for use in the flow.

    Note: The prefix for your Status column may be different.

Exercise 2 – Create automated flow

Task 2.1 - Create the trigger

  1. Navigate to the Power Automate portal https://make.powerautomate.com

  2. Make sure you are in the Dev One environment.

  3. Select the + Create tab from the left navigation menu.

  4. Select Automated cloud flow.

  5. Enter Opportunity Closed for Flow name.

  6. Enter Dataverse in search all triggers.

  7. Select When a row is added, modified, or deleted.

  8. Select Create.

Task 2.2 - Configure the trigger

  1. Select the When a row is added, modified, or deleted step.

  2. Select the When a row is added, modified, or deleted step name and enter Opportunity changed

  3. Select Modified for Change Type.

  4. Select Opportunities for Table Name.

  5. Select Organization for Scope.

    Screenshot of update row trigger.

Task 2.3 - Send email

  1. Select the + icon under the trigger step and select Add an action.

  2. Enter email in search.

  3. Select Send an email (V2) under Office 365 Outlook.

  4. Select Send an email (V2) step name and enter Notify by email

  5. Select To field and select Enter custom value.

  6. Enter your tenant user id for To.

  7. Select Subject field and enter Opportunity closed

  8. Select Body field and select the Dynamic content icon.

  9. Select Opportunity Subject from Opportunity changed.

  10. Select Body field and select the Dynamic content icon and select See more.

  11. Select Status from Opportunity changed.

Task 2.4 - Column filter

  1. Select the Opportunity changed trigger step.

  2. Select Show all

  3. Select the Select Columns field and enter the Logical name from the previous exercise, for example: cr977_status

    Note: The prefix for your status column will be different.

Task 2.5 - Row filter

  1. Select the Opportunity changed step.

  2. Select Show all

  3. Select the Filter Rows field and enter cr977_status eq 3 using the Logical name from the previous exercise.

    Screenshot of trigger filter.

    Note: The prefix for your status column will be different.

  4. Select Save.

  5. Select the <- Back button from the top left of the command bar.