导航

AX 2012 query应用collections

Posted on 2015-05-12 14:31  Tokywu  阅读(143)  评论(0编辑  收藏  举报
1 QueryBuildRange range;
2 
3     super();
4 
5     this.query().dataSourceName('VendTop10VendorsByPurchase').clearDynalinks();
6 
7     // setting range so that only invoices within the year are calculated
8     range = this.query().dataSourceName('VendTop10VendorsByPurchase').addRange(fieldNum(VendTop10VendorsByPurchase, InvoiceDate));
9     range.value(strFmt('(InvoiceDate >= %1)', date2StrXpp(systemDateGet() - dayOfYr(systemDateGet()) + 1)));

 

 

 

 

 

 

                                          updated by toky 20150512