Bug 206106 If dataset filter refer to a report parameter, we should also retrieve the data from rptconfig first[0705]
Description: To be consistent with the Dataset parameter, if dataset filter refers to a report parameter, we should also retrive the value from rptconfig first[0705] Build number: 2.2.2.v20071012-0630 Steps to reproduce: 1, New a allow multiple select value parameter and new two static value: 161, 167. 1, New a CUSTOMER Dataset 2, New a dataset filter and the filter condition refer to a report parameter such as: Expression: row["CUSTOMERNUMBER"] Operator: In Value: params["p1"] 3, Drag the dataset into layout 4, Preview 5, Go back to layout and preview the dataset Expected result: 161 and 167 rows are in the preview results Actual result: Nothing displayed in layout because we do not retrieve the values from the rptconfig. Error log:
data/org.eclipse.birt.report.data.adapter/src/org/eclipse/birt/report/data/adapter/api/script/DataAdapterTopLevelScope.java
{
		if ( !( params instanceof ScalarParameterHandle ) )
			return null;
		ScalarParameterHandle sp = (ScalarParameterHandle) params;
		String defaultValue = sp.getDefaultValue( );
		String type = sp.getDataType( );
		if ( defaultValue == null )
		{
			
			if ( sp.allowNull( ) )
				return null;
			
			if ( DesignChoiceConstants.PARAM_TYPE_STRING.equals( type ) )
			{
				return "";
			}
			if ( DesignChoiceConstants.PARAM_TYPE_FLOAT.equals( type ) )
				return new Double( 0 );
			if ( DesignChoiceConstants.PARAM_TYPE_DECIMAL.equals( type ) )
				return new BigDecimal( (double) 0 );
			if ( DesignChoiceConstants.PARAM_TYPE_DATETIME.equals( type ) )
				return new Date( 0 );
			if ( DesignChoiceConstants.PARAM_TYPE_DATE.equals( type ) )
				return new java.sql.Date( 0 );
			if ( DesignChoiceConstants.PARAM_TYPE_TIME.equals( type ) )
				return new java.sql.Time( 0 );
			if ( DesignChoiceConstants.PARAM_TYPE_BOOLEAN.equals( type ) )
				return Boolean.FALSE;
			if ( DesignChoiceConstants.PARAM_TYPE_INTEGER.equals( type ) )
				return new Integer( 0 );