Server User Guides > Survey Tabulation > Overview of UNICOM Intelligence Reporter - Survey Tabulation > UNICOM Intelligence Reporter - Survey Tabulation architecture > Table Population Sequence
 
Table Population Sequence
The following diagram shows the interaction between the Table Object Model and the other main components when tables are populated. In UNICOM Intelligence Reporter - Survey Tabulation, these components are located on the server. In UNICOM Intelligence Reporter, the components are located on the client. All interaction with these components takes place through the Table Object Model and, in normal circumstances, you do not access these components directly. In this diagram the arrows show the passage of data and control specifications.
This graphic is described in the surrounding text.
Table Aggregator (coaggr2.dll)
The Table Aggregator performs a pass through the case data to extract the raw numeric counts that are required for the tables being populated. It also calculates some intermediate values from the extracted data, such as the sum of the squared weights for use in statistical tests, and performs some calculations on the extracted data, such as the calculation of percentiles. As input the Table Aggregator takes a reference to an MDM document and an aggregation request XML file, which is generated by the Table Object Model. The output of the Table Aggregator is a raw binary file, which is passed to the Table Builder.
Table Builder (tbcom2.dll)
The Table Builder reads the raw binary file (generated by the Table Aggregator) and a table structure XML file (generated by the Table Object Model) and performs post-aggregation numerical processing on the data. For example, the Table Builder calculates any percentages, summary statistics (for example, mean and standard deviation), and statistical tests that have been requested. The Table Builder formats the results and passes them to the Table Object Model in the form of a results XML file, which contains cell values plus some additional information about the tables. If any statistical tests have been performed, the Table Builder also outputs raw information from the statistical tests.
UNICOM Intelligence Data Model
The UNICOM Intelligence Data Model handles all communication with the case data and metadata.
When an instance of a Table Object Model Document is created, instances of the Table Aggregator and Table Builder are automatically created. Each instance of a Table Object Model Document has its own instance of the Table Aggregator and Table Builder.
Sequence of events when the Populate method is called
1 The Table Object Model writes two temporary files, one containing the aggregation request XML and the other containing the table structure XML. This information is created by the Table Object Model as follows:
The regular tables XML is created in memory, but only for the tables that are to be populated. At this point, any derived variables that are required are also created and are referenced by the Variable attribute instead of the original MDM variable.
The global table settings are merged into the XML for each separate table.
Any statistical tests that are invalid for their table are discarded.
Unique dimension IDs are assigned to each axis and cell item across all tables.
Filter variables are created in the MDM Document as required and the variable names are inserted into the tables XML.
Two different XSLTs are applied to the post-processed tables XML (which is still in-memory only). One XSLT produces the aggregation request XML and the other produces the table structure XML. These two XML files are written to disk with temporary file names.
2 The Table Aggregator object is given a reference to the MDM Document, the name of the aggregation request XML file, and the name of the file to write the results into. The Table Aggregator processes the case data and writes the results into the specified output file (sometimes called the nums file).
3 The Table Builder is given the names of the table structure XML and nums files as input and the names of the results XML and statistics data files to use for output. The Table Builder performs some post-processing on the raw numbers produced by the Table Aggregator to create the final numbers that are to appear in the table. These are written into the specified results XML file. If any statistical tests were requested, additional information about these tests is written into the specified statistics data file.
4 The Table Object Model loads the results (cell values and heading IDs) from the results XML file generated by the Table Builder.
5 If the Document.KeepLogFiles property has been set to True, all the temporary files are given meaningful file names, otherwise all temporary files are deleted. In a multiuser environment, the Document.LogFilePath should be set to a unique value for each user to stop the files for each user getting mixed up.
See also
UNICOM Intelligence Reporter - Survey Tabulation architecture
Internal files used by the Table Object Model
XML formats used by the Table Object Model
UNICOM Intelligence Data Model
Table scripting
UNICOM Intelligence Reporter - Survey Tabulation architecture