Skip to main content

Notifications

Announcements

No record found.

Dynamics 365 Community / Blogs / DaxGeek / Example of Modifying a Data...

Example of Modifying a Data Source Query

The following code illustrates the necessary modifications on a form that
contains one data source related to the table InventTrans:



 1
2
3
4
5
6
7
8
9
10
11
public void init()
{
QueryBuildDataSource dataSource;
super();
dataSource =
this.query().dataSourceTable(tableNum(InventTrans));
dataSource.addGroupByField(fieldNum(InventTrans,
ItemId));
dataSource.addSelectionField(fieldNum(InventTrans,
Qty), SelectionField::Sum);
}

Best Regards,
Hossein Karimi

Comments

*This post is locked for comments