# fieldvaluecount - 脚本函数

此脚本函数用于返回字段中特殊值的数量。fieldname 必须指定为字符串（例如引用的文字）。

语法：

fieldvaluecount(fieldname)

示例：

在此例中，在 RegionCount 变量中计算并存储区域的数量。在此例中，此值为 2，然后在需要知道现有区域数量的情况下可用于进一步转换。

`LOAD * INLINE
` `[ Region, Year, Month, Sales
` `South,	2014,	June,	645
` `North,	2014,	May,	245
` `North,	2014,	May,	347
` `North,	2014,	June,	127
` `South,	2013,	May, 367
` `South,	2013,	July,	221
];
` ` ` `
Let RegionCount = FieldValueCount('Region');`