Program: 68295
Project: 68295
Buggy source:
/** 
 * Get resultSet
 * @return
 */
private IQueryResults executeProcess(DataRequestSession session,ExecutionContext context){
  errorList=new ArrayList();
  try {
    metaData=((DataSetEditor)this.getContainer()).getCurrentItemModel();
    columnCount=metaData == null ? 0 : metaData.length;
    QueryDefinition query=new QueryDefinition();
    query.setDataSetName(ExternalUIUtil.getQulifiedDataSetHandle(((DataSetEditor)getContainer()).getHandle()).getQualifiedName());
    int maxRow=getMaxRowPreference();
    query.setMaxRows(maxRow);
    PropertyHandle handle=((DataSetEditor)getContainer()).getHandle().getPropertyHandle(DataSetHandle.PARAMETERS_PROP);
    if (handle != null) {
      Iterator paramIter=handle.iterator();
      while (paramIter.hasNext()) {
        String value=null;
        DataSetParameterHandle paramDefn=(DataSetParameterHandle)paramIter.next();
        if (paramDefn.isInput()) {
          if (paramDefn instanceof OdaDataSetParameterHandle && ((OdaDataSetParameterHandle)paramDefn).getParamName() != null) {
            String linkedReportParam=((OdaDataSetParameterHandle)paramDefn).getParamName();
            if (linkedReportParam != null) {
              ParameterHandle ph=((DataSetEditor)getContainer()).getHandle().getModuleHandle().findParameter(linkedReportParam);
              if (ph instanceof ScalarParameterHandle) {
                if (((ScalarParameterHandle)ph).getParamType().equals(DesignChoiceConstants.SCALAR_PARAM_TYPE_MULTI_VALUE)) {
                  throw new BirtException(Messages.getFormattedString("String_Node_Str",new String[]{linkedReportParam}),null);
                }
              }
            }
            value=DataUtil.getParamValue(((DataSetEditor)getContainer()).getHandle(),(OdaDataSetParameterHandle)paramDefn);
          }
          if (value != null) {
            InputParameterBinding binding=new InputParameterBinding(paramDefn.getName(),new ScriptExpression(value));
            query.addInputParamBinding(binding);
          }
        }
      }
    }
    columnBindingNames=new String[columnCount];
    ScriptExpression[] expressions=new ScriptExpression[columnCount];
    for (int n=0; n < columnCount; n++) {
      columnBindingNames[n]=metaData[n].getName();
      expressions[n]=new ScriptExpression(ExpressionUtil.createJSDataSetRowExpression(metaData[n].getName()));
      expressions[n].setDataType(metaData[n].getDataType());
      query.addResultSetExpression(columnBindingNames[n],expressions[n]);
    }
    boolean needCache=false;
    if (this.previousMaxRow != maxRow) {
      this.previousMaxRow=maxRow;
      needCache=true;
    }
    DataSetExecutorHelper helper=new DataSetExecutorHelper();
    IQueryResults resultSet=helper.execute(ExternalUIUtil.getQulifiedDataSetHandle(((DataSetEditor)getContainer()).getHandle()),query,true,true,needCache,context,session);
    return resultSet;
  }
 catch (  BirtException e) {
    errorList.add(e);
    return null;
  }
}

Fixed version (ground truth):
/** 
 * Get resultSet
 * @return
 */
private IQueryResults executeProcess(DataRequestSession session,ExecutionContext context){
  errorList=new ArrayList();
  try {
    metaData=((DataSetEditor)this.getContainer()).getCurrentItemModel();
    columnCount=metaData == null ? 0 : metaData.length;
    QueryDefinition query=new QueryDefinition();
    query.setDataSetName(ExternalUIUtil.getQulifiedDataSetHandle(((DataSetEditor)getContainer()).getHandle()).getQualifiedName());
    int maxRow=getMaxRowPreference();
    query.setMaxRows(maxRow);
    registerParameterBinding(query,((DataSetEditor)getContainer()).getHandle(),session);
    columnBindingNames=new String[columnCount];
    ScriptExpression[] expressions=new ScriptExpression[columnCount];
    for (int n=0; n < columnCount; n++) {
      columnBindingNames[n]=metaData[n].getName();
      expressions[n]=new ScriptExpression(ExpressionUtil.createJSDataSetRowExpression(metaData[n].getName()));
      expressions[n].setDataType(metaData[n].getDataType());
      query.addResultSetExpression(columnBindingNames[n],expressions[n]);
    }
    boolean needCache=false;
    if (this.previousMaxRow != maxRow) {
      this.previousMaxRow=maxRow;
      needCache=true;
    }
    DataSetExecutorHelper helper=new DataSetExecutorHelper();
    IQueryResults resultSet=helper.execute(ExternalUIUtil.getQulifiedDataSetHandle(((DataSetEditor)getContainer()).getHandle()),query,true,true,needCache,context,session);
    return resultSet;
  }
 catch (  BirtException e) {
    errorList.add(e);
    return null;
  }
}