Dynamics 365 ERP - Development
Category
Jan 26, 2024
Published date
Text
Article Type
AI Summary
- The article discusses the limitation of filtering data within certain form grid columns in Dynamics 365 for Finance and Operations when the column is bound to a display method.
- The article suggests a workaround to make dynamically calculated columns searchable by using views as the data source for grid columns instead of directly displaying data from tables using display methods.
- Views in D365FO are virtual tables based on the result-set of an SQL statement, containing rows and columns from one or more real tables in the database.
- The article provides an example of using the DocEventRuleGridView form, where the DocEventRuleView view is used as the data source, which contains fields from the standard EventRule table and additional calculated columns.
- Calculated columns in the view are regular columns whose values are the result of calculations in methods, and they can be bound to the methods that return the values.
- The article highlights that methods returning values for calculated columns must calculate the value using SQL syntax only, and the SysComputedColumn framework can be used to calculate the value.
- By using views with calculated columns as the form data source, the view collects the data from its data sources, calculates the values of its calculated columns, and stores the collected data in memory, allowing users to apply filters based on this data.
- The article concludes by emphasizing the importance of creating appropriate indexes for columns in the view to optimize performance when dealing with large amounts of data.
Registered users can view the full text for FREE!
Sign In Now!