UiPath Documentation
apps
2023.4
false
Apps 用户指南
重要 :
请注意,此内容已使用机器翻译进行了部分本地化。 新发布内容的本地化可能需要 1-2 周的时间才能完成。

函数:Filter

提示:

To better understand how the Filter function works, check out the Using Apps with Data Service pages in the How To section.

使用此函数可根据表格的字段筛选表格。

此函数执行不区分大小写的检查。

提示:

根据项目的需求,您可以选择在使用“筛选”功能时排除某些条件。 要排除条件,您可以编写一个表达式,将筛选字段(条件数组的第一个参数)解析为null 。 例如,您可以使用以下内容:

Filter(Customer, [If(IsBlank(Dropdown.Value), null, City), "=", Dropdown.Value])

In this case, the filter on City is only applied when the Dropdown contains a value other than blank.

语法 描述 示例

筛选 (实体和条件)

该函数返回所有结果为 true 的记录。这些表达式可以按名称引用字段/列。

docs image

参数

参数 类型 描述

Entity

必填

要搜索的实体(例如,控件的数据属性)。

Condition

必填

用于在实体中查找的条件。

Condition参数的格式应如下所示:

[Entity Field, Operator, Value]

可以使用以下运算符:

  • contains
  • not contains
  • startswith
  • endswith
  • =
  • !=
  • >
  • <
  • >=
  • <=
  • in
  • not in

示例

Filter(Customer, [City, "=", New York]) :加载的表格仅显示来自纽约市的客户的信息

  • 参数
  • 示例

此页面有帮助吗?

连接

需要帮助? 支持

想要了解详细内容? UiPath Academy

有问题? UiPath 论坛

保持更新