DteResultSet resultSet = new DteResultSet( dteResults.getID( ), dteResults.getResultIterator( ), this, context );
DataSetID dataSetId = new DataSetID( dteResults.getID( ) ); DteResultSet resultSet = new DteResultSet( dataSetId, parentResult, dteResults .getResultIterator( ), this, context );
	protected IResultSet doExecuteQuery( DteResultSet parentResult,			IQueryDefinition query )	{		String queryID = (String) queryIDMap.get( query );		try		{			IQueryResults parentQueryResults = null;			if ( parentResult != null )			{				parentQueryResults = parentResult.getQueryResults( );			}			String resultSetID = null;			if ( parentQueryResults == null )			{				resultSetID = getResultID( null, -1, queryID );			}			else			{				String pRsetId = parentQueryResults.getID( );				long rowid = parentResult.getRawID( );				resultSetID = getResultID( pRsetId, rowid, queryID );			}						if ( resultSetID == null )			{				logger.log( Level.SEVERE, "Can't load the report query" );				return null;			}			//((QueryDefinition)query).setDataSetName( null );			((QueryDefinition)query).setQueryResultsID( resultSetID );			IPreparedQuery pQuery = dteEngine.prepare( query );						Scriptable scope = context.getSharedScope( );			IQueryResults dteResults; // the dteResults of this query			if ( parentQueryResults == null )			{				// this is the root query				dteResults = pQuery.execute( scope );			}			else			{				// this is the nest query, execute the query in the				// parent results				dteResults = pQuery.execute( parentQueryResults, scope );			}			DteResultSet resultSet = new DteResultSet( dteResults.getID( ),					dteResults.getResultIterator( ), this, context );						rsets.addFirst( resultSet );			return resultSet;		}		catch ( BirtException be )		{			logger.log( Level.SEVERE, be.getMessage( ) );			context.addException( be );			return null;		}	}