英文:
can we create business rules that span across different table in dataverse
问题
我有一个从学生表到班级表的一对多关系,班级表中的查找列是学生表中的学生ID。班级表有一个名为"状态"的列,如果班级表中的所有记录的"状态"都是"已完成",我想要学生表中的"学习状态"列为"已完成",否则为"未完成"。如何在Dataverse中实现这个功能?
英文:
I have a one to many relationship from Student table and Class table, the lookup column in Class table is Student ID in Students Table. Class table has a column which is "Stutas", if all the records in Stauts in class table are "finished", I want the Student table's column "StudyStatus" to be "Completed", otherwise "Uncompleted". how to do it in Dataverse?
答案1
得分: 0
这无法通过业务规则实现。
我看到3个选项:
- 在表Student上注册的插件
- 经典工作流
- Power Automate流
插件在技术上是理想的解决方案:可以在事务内同步保持Student上的状态,处理要求最少。但是,您需要开发代码。
经典工作流在事务中也可以运行(当同步执行时),但在这里使其正常工作仍需要自定义代码。
使用Power Automate流,您可以在不编程的情况下构建解决方案。但是,PA流是异步执行的。
请记住,您可能不仅需要处理更新触发器,还需要处理创建和删除触发器。
英文:
It is not possible to do this with business rules.
I see 3 options:
- Plugin registered on table Student
- Classic workflow
- Power Automate flow
A plugin is technically the ideal solution: status on Student can be kept in sync within a transaction and processing requires minimal processing. However, you would need to develop code.
A classic workflow can also run in transaction (when it is executed synchronously), but making things work here still requires custom code.
With a Power Automate flow you can build your solution without programming. However, a PA flow is executed asynchronously.
> Keep in mind that you may need to address not only the update trigger, but also the create and delete triggers.
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论