populateQueryExprMapping(subqueryDefn);   SubqueryDefinition subSubqueryDefn = new SubqueryDefinition( "IAMTEST2" ); subGroupDefn[0].addSubquery( subSubqueryDefn );  bindingNameGroup = new String[1]; bindingNameGroup[0] = "GROUP_COL3"; bindingExprGroup = new IBaseExpression[1]; bindingExprGroup[0] = new ScriptExpression("dataSetRow.COL3"); GroupDefinition[] subSubGroupDefn = new GroupDefinition[] { new GroupDefinition( "group3") };  subSubGroupDefn[0].setKeyExpression( "row.GROUP_COL3" );  for ( int k = 0; k < subSubGroupDefn.length; k++ ) { if ( bindingNameGroup != null ) for ( int i = 0; i < bindingNameGroup.length; i++ ) subSubqueryDefn.addResultSetExpression( bindingNameGroup[i], bindingExprGroup[i] );
populateQueryExprMapping( subqueryDefn );
		protected IQueryDefinition getDefaultQueryDefnWithSubQuery( String dataSetName )		{			IQueryDefinition queryDefn = getDefaultQueryDefn( dataSetName );						// row.Col1			GroupDefinition groupDefn = (GroupDefinition) queryDefn.getGroups().get(1);						// ---------- begin sub query ----------			SubqueryDefinition subqueryDefn = new SubqueryDefinition( "IAMTEST" );			groupDefn.addSubquery( subqueryDefn );						String[] bindingNameGroup = new String[1];			bindingNameGroup[0] = "GROUP_COL2";			IBaseExpression[] bindingExprGroup = new IBaseExpression[1];			bindingExprGroup[0] = new ScriptExpression("dataSetRow.COL2");			GroupDefinition[] subGroupDefn = new GroupDefinition[] { new GroupDefinition(					"group2") };			//subGroupDefn[0].setKeyExpression( "row.GROUP_COL2" );			subGroupDefn[0].setKeyExpression( "row.GROUP_COL2" );						for (int k = 0; k < subGroupDefn.length; k++) {				if (bindingNameGroup != null)					for (int i = 0; i < bindingNameGroup.length; i++)						subqueryDefn.addResultSetExpression(								bindingNameGroup[i], bindingExprGroup[i]);								for (int i = 0; i < subGroupDefn.length; i++)					subqueryDefn.addGroup(subGroupDefn[i]);			}			populateQueryExprMapping(subqueryDefn);							// --- sub query of sub query				SubqueryDefinition subSubqueryDefn = new SubqueryDefinition( "IAMTEST2" );				subGroupDefn[0].addSubquery( subSubqueryDefn );								bindingNameGroup = new String[1];				bindingNameGroup[0] = "GROUP_COL3";			    bindingExprGroup = new IBaseExpression[1];				bindingExprGroup[0] = new ScriptExpression("dataSetRow.COL3");				GroupDefinition[] subSubGroupDefn = new GroupDefinition[] { new GroupDefinition(						"group3") };				//subSubGroupDefn[0].setKeyExpression( "row.GROUP_COL3" );				subSubGroupDefn[0].setKeyExpression( "row.GROUP_COL3" );								for ( int k = 0; k < subSubGroupDefn.length; k++ )				{					if ( bindingNameGroup != null )						for ( int i = 0; i < bindingNameGroup.length; i++ )							subSubqueryDefn.addResultSetExpression( bindingNameGroup[i],								bindingExprGroup[i] );					for ( int i = 0; i < subSubGroupDefn.length; i++ )						subSubqueryDefn.addGroup( subSubGroupDefn[i] );				}				populateQueryExprMapping(subSubqueryDefn);				// --- sub query of sub query						// ---------- end sub query ----------						return queryDefn;		}