SELECT
e.DESCRIPTION AS [EQUIPMENT TYPE],
Count(e.EQNAME) AS QUANTITY,
Sum(IIf(e.CONDITION = 'Functional', 1, 0)) AS WORKING,
Sum(IIf(e.CONDITION = 'Non-Functional', 1, 0)) AS [NON-WORKING]
FROM EQUIPMENTS AS e
GROUP BY e.DESCRIPTION;
我尝试在 VB.net TableAdapter 查询配置向导中使用此查询,但出现错误。
函数参数列表中的错误:“=”无法识别。无法解析查询文本 GROUP BY 子句中的错误。
此查询在 MS Access 中运行良好,与 VB.Net 有什么区别?