oSum.setString(3, getString(DB.gu_workarea));
oSum.setString(4, getString(DB.gu_product));
oSum.setString(5, getString(DB.gu_workarea));
oSum.setString(7, getString(DB.gu_workarea));
Term oZone = new Term();
oZone.load(oConn, getString(DB.gu_geozone));
LinkedList oChlds = oZone.getChilds(oConn, Term.SCOPE_ALL);
ListIterator oIter = oChlds.listIterator();
while (oIter.hasNext()) {
oZone = (Term) oIter.next();
oSum.setString(6, oZone.getString(DB.gu_term));
oSum.setString(8, oZone.getString(DB.gu_term));
oRst = oSum.executeQuery();
oRst.next();
if (DebugFile.trace)
DebugFile.writeln(" sales for "+oZone.getString(DB.tx_term)+" = "+String.valueOf(oRst.getFloat(1)));
fSum += oRst.getFloat(1);
oRst.close();
} // wend
if (DebugFile.trace)
DebugFile.writeln(" subtotal sales for all child zones = "+String.valueOf(fSum));
oSum.setString(6, getString(DB.gu_geozone));
oSum.setString(8, getString(DB.gu_geozone));
oRst = oSum.executeQuery();
oRst.next();
if (DebugFile.trace) {
oZone.load(oConn, getString(DB.gu_geozone));
DebugFile.writeln(" sales for zone "+oZone.getString(DB.tx_term)+" = "+String.valueOf(oRst.getFloat(1)));
}
fSum += oRst.getFloat(1);
oRst.close();
oSum.close();