在 Azure 逻辑应用程序中尝试为特定于 D365 的数据类型开发动态筛选器查询时,如何解决不兼容的类型错误?

How can I solve an incompatible types error when trying to develop a dynamic filter query for D365-specific data types in Azure Logic Apps?

我目前正在尝试使用 Azure Logic Apps 列出 Dynamics 365 Finance & Operations 中 Table 中存在的项目,使用运行时输入确定的动态 filterQuery,如下所示: D365 F&O connector for List Items present in table

但是,对于某些过滤器查询,我们遇到了 D365 中的数据类型与 Logic Apps 中的数据类型不同的错误,导致类型不兼容的错误,如下所示: Error message received from logic app - A binary operator with incompatible types was detected

供参考,为了满足动态过滤要求,我正在做的是使用循环以这种方式将所有必需的过滤器连续附加到字符串,从确定的JSON有效负载中提取键值对在运行时: Append to filter query: and eq ''

抛出错误的字段的数据类型分别为D365“enum”和“bool”。 Bool 数据类型有错误:“检测到具有不兼容类型的二元运算符。找到运算符种类 'Equal' 的操作数类型 'Microsoft.Dynamics.DataEntities.NoYes' 和 'Edm.String'”。 枚举数据类型有错误:“检测到具有不兼容类型的二元运算符。找到运算符类型 'Microsoft.Dynamics.DataEntities.' 和 'Edm.String' 运算符种类 'Equal'”,我希望的键的名称在哪里过滤。

有没有简单的方法可以解决这个错误?非常感谢!

此问题已在此处解决:https://docs.microsoft.com/en-us/answers/questions/314559/azure-logic-apps-to-d365-fampo-flow-results-in-dif.html

但是,在这种情况下,我建议:

  1. 首先 运行 没有过滤器的 Flow with Dynamics 动作。
  2. 其次检查 Flow 的结果 运行,并查找您要对其进行过滤的值。
  3. 第三次复制字段名称(不带引号)并在过滤器中使用该 属性 名称(带条件)。