ElementSymbol element = (ElementSymbol) elemIter.next();
GroupSymbol group = element.getGroupSymbol();
//assumes that all non-xml group elements are temp elements
boolean hasTempElement = !metadata.isXMLGroup(group.getMetadataID());
if(!first && hasTempElement && resultSet == null) {
throw new QueryPlannerException("ERR.015.004.0035", QueryPlugin.Util.getString("ERR.015.004.0035", conjunct)); //$NON-NLS-1$ //$NON-NLS-2$
}
if (hasTempElement) {
String currentResultSet = metadata.getFullName(element.getGroupSymbol().getMetadataID());
if (resultSet != null && !resultSet.equalsIgnoreCase(currentResultSet)) {
throw new QueryPlannerException(QueryPlugin.Util.getString("CriteriaPlanner.multiple_staging", conjunct)); //$NON-NLS-1$
}
resultSet = currentResultSet;
}
first = false;
}
if (resultSet != null) {
Collection functions = ContextReplacerVisitor.replaceContextFunctions(conjunct);
if (!functions.isEmpty()) {
throw new QueryPlannerException(QueryPlugin.Util.getString("CriteriaPlanner.staging_context")); //$NON-NLS-1$
}
//should also throw an exception if it contains a row limit function
}