Use methods in where statements

拈花ヽ惹草 提交于 2019-12-02 01:54:18

You cannot use methods in the where expression (nor in any other part, for that matter) of the select statement in AX. Your example will not compile successfully.

You can either try incorporating the logic of your foo method in the where expression or iterate through the result of the select statement and call method foo for each record individually e.g.:

Table table;

while select table
    where table.id != this.id
{
    if (this.foo(table))
    {
        info(table.id);
    }
}
标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!