Skip to content

Commit 2cf39a9

Browse files
committed
Doc for expression builder feature (Power Apps maker)
1 parent 6c402e4 commit 2cf39a9

8 files changed

+143
-0
lines changed
Lines changed: 143 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,143 @@
1+
---
2+
title: "Create or edit filters in model-driven app views | MicrosoftDocs"
3+
description: "Learn how to create and edit filters or views for your app"
4+
keywords: ""
5+
ms.date: 2/04/2020
6+
ms.service: powerapps
7+
ms.custom:
8+
ms.topic: article
9+
applies_to:
10+
- "Dynamics 365 (online)"
11+
- "Dynamics 365 Version 9.x"
12+
- "powerapps"
13+
ms.assetid:
14+
author: iangpgh
15+
ms.author: v-iapr
16+
manager: matp
17+
ms.reviewer: srihas
18+
ms.suite:
19+
ms.tgt_pltfrm:
20+
caps.latest.revision: 25
21+
topic-status: Drafting
22+
search.audienceType:
23+
- maker
24+
search.app:
25+
- PowerApps
26+
- D365CE
27+
---
28+
29+
# Create or edit filters in model-driven app views
30+
31+
<a name="BKMK_CreateOrEditViewFilters"></a>
32+
33+
The filters in a Power Apps view are important to the value provided by the view. Which filters are applied determine which records appear in the list by default. You can add or edit a filter for the columns that you include in a view by selecting the column and selecting **Filter by**. You can also use the Filters editor in the view designer. Use the Filters editor to add or edit filters for any fields in the view entity or any fields in a related entity.
34+
35+
In this topic, you create or edit filters by performing the following tasks:
36+
37+
- [Edit or remove a filter condition](create-edit-view-filters.md#edit-or-remove-a-filter-condition)
38+
39+
- [Add or edit conditions to the filter](create-edit-view-filters.md#add-or-edit-conditions-to-the-filter)
40+
41+
- [Open the filter editor](create-edit-view-filters.md#open-the-filter-editor)
42+
43+
- [Add a condition to a filter](create-edit-view-filters.md#add-a-condition-to-a-filter)
44+
45+
- [Add a group condition to a filter](create-edit-view-filters.md#add-a-group-condition-to-a-filter)
46+
47+
- [Add a related entity to a condition](create-edit-view-filters.md#add-a-related-entity-to-a-condition)
48+
49+
- [Group conditions of a filter](create-edit-view-filters.md#group-conditions-of-a-filter)
50+
51+
## Edit or remove a filter condition
52+
53+
1. Sign in to [Power Apps](https://make.powerapps.com/?utm_source=padocs&utm_medium=linkinadoc&utm_campaign=referralsfromdoc).
54+
55+
2. Expand **Data**, select **Entities**, select the entity that you want, and then select the **Views** tab.
56+
57+
3. Select a view to open it. The View properties panel lists existing filters.
58+
59+
> [!div class="mx-imgBorder"]
60+
> ![View panel filters](media/views-panel-filters.png)
61+
62+
4. On the View properties panel, select a filter condition.
63+
64+
> [!div class="mx-imgBorder"]
65+
> ![Edit filters](media/edit-filter-viewpanel.png)
66+
67+
5. Select the conditional operator that you want to use.
68+
69+
6. Type or select the comparison value for the condition.
70+
71+
7. Select **Apply**.
72+
73+
8. To remove a condition, select Remove filter. The condition is removed without confirmation.
74+
75+
### Open the filter editor
76+
77+
- On the View properties panel, select **Edit filters**.
78+
79+
> [!div class="mx-imgBorder"]
80+
> ![Filters editor](media/edit-create-filters.png)
81+
82+
### Add a condition to a filter
83+
84+
1. In the filters editor, select **Add > Add row**.
85+
86+
2. Select a field for the condition.
87+
88+
3. Select a conditional operator.
89+
90+
4. Select a comparison value.
91+
92+
Some filter conditions do not require a comparison value for the condition. For example, the operator **Contains data** does not require a comparison value. With other filter conditions, you choose the comparison value from an option set. For example, the status field has an option set that contains the values Active and Inactive.
93+
94+
> [!div class="mx-imgBorder"]
95+
> ![Filter condition](media/add-condition-filter.png)
96+
97+
5. Select **OK**.
98+
99+
### Add a group condition to a filter
100+
101+
1. In the filters editor, select **Add > Add group**.
102+
103+
2. Select the relational operator **Or** for the group. **And** is the default relational operator.
104+
105+
3. Specify the first clause of the grouped condition. Select the field, conditional operator, and comparison value.
106+
107+
4. Select **Add > Add group**
108+
109+
5. Specify the second clause of the grouped condition.
110+
111+
> [!div class="mx-imgBorder"]
112+
> ![Group condition filter](media/add-group-filter.png)
113+
114+
You can select **Collapse** to display the group as a conditional expression.
115+
116+
### Add a related entity to a condition
117+
118+
1. In the filters editor, select **Add > Add related entity**.
119+
120+
2. Select a field from the related entity for the condition. You can select fields that have a Many to One, One to Many, or Many to Many relationships with the view entity.
121+
122+
3. Select a conditional operator.
123+
124+
4. Select or enter a comparison value.
125+
126+
> [!div class="mx-imgBorder"]
127+
> ![Related entity filter](media/add-relatedentity-filter.png)
128+
129+
### Group conditions of a filter
130+
131+
1. In the filters editor, select the checkbox for the conditions that you want to group.
132+
133+
2. Select the More commands menu for one of the conditions, and select **Make group**.
134+
135+
3. To ungroup a group, select More commands menu for the group, and select **Ungroup**
136+
137+
> [!div class="mx-imgBorder"]
138+
> ![Grouped condition filter](media/group-conditions-filter.png)
139+
140+
### Next steps
141+
[Choose and configure columns](choose-and-configure-columns.md)
142+
[Edit filter criteria](edit-filter-criteria.md)
143+
[Create 1:N (one-to-many) or N:1 (many-to-one) relationships](../common-data-service/create-edit-1n-relationships.md)
Loading
Loading
Loading
Loading
Loading
Loading
Loading

0 commit comments

Comments
 (0)