The swArchitect client offers Architects a Database Statistics Report that can provide evidence and input to decision making before any refactoring or changes to the meta model are executed.


Prerequisites


Viewing the Report

In the swArchitect client, you can generate this report from either the Metadata tab or the Refactorings tab. 




Note: For large databases, it is recommended that the report is generated only when no or few users are connected to the server, since the generation may affect the response time of the server.



When the report is finished, it will open in a read-only Description editor:


The report contains three sections as described below. Any types with "0" counts will be highlighted in red, as seen in the above example. Types with "0" counts may be candidates for deletion, unless they are so recent that no one has had the chance to use them.


Item Types

The Item Types section lists provides statistics on the use of all item types.


SID

The SID of the item type.


Name

The name of the item type.


Count

The number of item instances of the item type. If the type is not used (count is 0), this is indicated by a red background color, and such types can be candidates for deletion, unless they are so recent that no one has had the chance to use them.


Note: Abstract types are never uses, and will always indicate "0". Therefore, they are not highlighted in red.


Def Parts

The number of parts which have used items of the type as Def Obj.

A high number indicates a high "effectivity" of the type since every item is used many times. A low number, relative to the Count may indicate that the item type may be better transformed into an attribute instead. Note, however, that some item types are supposed to be "top items" that are never used as parts.


Nodes

Indicates the total number of nodes owned by the items. Note that all items (apart from Config Items) have at least one node, the top node of the item.


N/P

Indicates the ratio between the number of nodes and the number of parts owned by the items. 


Max Depth

The maximum depth of the node trees. A high number may indicate the use of a "risky" construct that may yield high number of nodes.


Size

A measurement of the total storage size for the items, including zipped description texts.


Mean Size

A measurement of the mean storage size.


Abstr.

Indicates whether the item type is set as an abstract type.


Depr.

Indicates whether the item type is deprecated.


Part Types

The Part Types section provides statistics on the use of all part types.


SID

The SID of the part type.


Name

The name of the part type.


Count

The total number of parts of the type. If the number is 0, the value is highlighted in red. 


Node Count

The total number of nodes created for the parts of the type, for structural parts.


Node Use Count

The total number of times the nodes (for structural parts) are referenced, as node attributes or DefObj/RefObj node 

references in parts. A value of 0 is highlighted in red. Such part types may be candidates for refactoring to simple part.


Use Part Name

Indicates whether parts of the type may have part names. If the value is True (i.e., part name may be used), but no part names are actually used (the Part Name Count value), the cell is highlighted in red, and the part type could be a candidate for losing its part name option.


Part Name Count

Total number of part names of the part, for parts where part names are allowed.


Depr.

Indicates whether the part type is deprecated.


Attribute Types

The Attribute Types section lists all Attribute types in the meta model.


SID

The SID of the attribute type.


Name

The name of the attribute type.


Count

The total number of actual attribute values of the type.


Size

A measurement of the total storage size for the attributes.


Mean Size

A measurement of the mean storage size.


Exporting the Report


The report can be saved to file using File > Save As..and selecting an available Save as type option.


Or,  the content can be copied (Ctrl+A and Ctrl+C) and pasted into a MS Word document. The table content can then be copied and saved into an MS Excel file.