Table.MatchesAllRows
指出資料表中的所有資料列是否都符合指定的條件。
Syntax
Table.MatchesAllRows(
table as table,
condition as function
) as logical
Remarks
指出 table 中的所有資料列是否都符合指定的 condition。如果所有資料列都符合,則傳回 true,否則傳回 false。
Examples
Example #1
判斷資料表中 [a] 資料行的所有資料列值是否都是偶數。
Table.MatchesAllRows(
Table.FromRecords({
[a = 2, b = 4],
[a = 6, b = 8]
}),
each Number.Mod([a], 2) = 0
)
Result:
true