executequery:passing range
public class FormRun extends ObjectRun
{
DimensionDefaultingController dimDefaultingController;
DimensionAttributevaluesetitem DimensionAttributevaluesetitemLoc;
QueryBuildDataSource qbds;
QueryBuildDataSource qbdsdimensionValue;
QueryBuildRange qbrIsExport, qbrdimValue;
}
public void init()
{
Query query;
super();
// here CustPackingSlipTrans_ds is only one of my datasource in form
// to initialise range for filtering records as per Financial dimension "Region"
query = CustPackingSlipTrans_ds.query();
qbds = query.dataSourceTable(tablenum(CustPackingSlipTrans));
qbds.clearRanges();
qbrIsExport = qbds.addRange(fieldnum(CustPackingSlipTrans,MSASNExport)); //.value(IsExport.valueStr());
qbdsdimensionValue = qbds.addDataSource(tableNum(DimensionAttributevaluesetitem));
qbdsdimensionValue.addLink(fieldNum(DimensionAttributevaluesetitem, DimensionAttributeValueSet), fieldNum(CustPackingSlipTrans, DefaultDimension));
qbdsdimensionValue.joinMode(JoinMode::ExistsJoin);
qbrdimValue = qbdsdimensionValue.addRange(fieldNum(DimensionAttributevaluesetitem, DisplayValue));
}
public void executeQuery()
{
qbrdimValue.value(FilterBy.valueStr());
qbrIsExport.value(IsExport.valueStr());
super();
}
//added in design field level
public boolean modified()
{
boolean ret;
ret = super();
custpackingslipTrans_ds.executeQuery();
return ret;
}
//added in design field level
public boolean modified()
{
boolean ret;
ret = super();
custpackingslipTrans_ds.executeQuery();
return ret;
}