var myQuery = new Query();
myQuery.where = "1 = 1";
myQuery.outFields = ["POB_TOT", "EDAD0015", "EDAD1664","EDAD65_"];
myQuery.returnGeometry = true;
var myQueryTask = new QueryTask(_poblacion);
myQuery.geometry = circle;
myQuery.spatialRelationship = Query.SPATIAL_REL_INTERSECTS;
var sumfields = new StatisticDefinition();
sumfields.statisticType = "sum";
sumfields.onStatisticField = "POB_TOT", "EDAD0015", "EDAD1664","EDAD65_";
myQuery.outStatistics = sumfields;