XML is an important format of information exchange and representation. One of its features is that it has tag representing semantics and hierarchy structure. Based on these features, an extensive aggregation of operation of XML data, XAggregation, is represented in this research. XAggregation permits XPath expression decorating dimension property and measure property. With XAggregation, statistics of XML data becomes more flexible with function of aggregating heterogeneous data and hierarchy data along some path of XML. XAggregation could be embedded in query language of XML such as XQuery. In this study the definition of XAggregation is presented, as well as the semantics and application of it. Implementation of XAggregation based on native XML database with XML as tree structure is also designed.