ListOrderedMapCI cMap = getAggregates();
OrderedMapIterator iMap = cMap.orderedMapIterator();
while (iMap.hasNext())
{
String key = (String) iMap.next();
SQLFunction f = (SQLFunction) iMap.getValue();
Column col = f.getColumn();
c.addAsColumn(key, new ColumnImpl(
null,
col.getTableName(),
col.getColumnName(),
f.getSqlExpression()));
if (!haveFromTable) // Last chance. Get it from the func.
{
{
// Kludgy Where table.col = table.col clause to force
// from table identification.