Bug 163770 [Smoke]Error in parameter dialog when preview dynamic parameter
Description: Error in parameter dialog when preview a report containing dynamic parameter. Build: 20061108 Steps to reproduce: 1. New data source and dataset 2. New a dynamic parameter based on the dataset. 3. Preview the report expected result: Correct parameter dialog. Actuaul result: See attached screen shot
engine/org.eclipse.birt.report.engine/src/org/eclipse/birt/report/engine/api/impl/GetParameterDefinitionTask.java
queryDefn.addResultSetExpression( valueColumnName, valueExpr );
				
				
				GroupDefinition groupDef = new GroupDefinition( );
				groupDef.setKeyColumn( valueColumnName );
				queryDefn.addGroup( groupDef );
				
				queryDefn.setAutoBinding( true );
				IPreparedQuery query = dteDataEngine.prepare( queryDefn, this.appContext );
				IQueryResults result = query.execute( executionContext
						.getSharedScope( ) );
				IResultIterator iter = result.getResultIterator( );
				int count = 0;
				while ( iter.next( ) )
				{
					String label = null;
					if ( labelExpr != null )
					{
						label = iter.getString( labelColumnName );
					}
					Object value = iter.getValue( valueColumnName );
					choices.add( new SelectionChoice( label, convertToType(
							value, dataType ) ) );
					count++;
					if ( ( limit != 0 ) && ( count >= limit ) )
					{
						break;
					}
					iter.skipToEnd( 1 ); 
				}