MartExplorer

Overview

MartExplorer provides a graphical user interface that enables the user to quickly and easily construct queries and execute them against mart datasets.

Each query is built and modified in a separate QueryEditor and the main window usually contains one or more of these. The QueryEditor contains three panels; a tree (top left), an input panel (top right) and a preview panel (bottom).The tree shows the current state of the query and can be used to change the contents of the input panel by clicking on the appropriate item; Attributes,Filters or Format. Attributes and filters can be added and removed using the appropriate input pages and the output format can be set via the format page.

The results of a query can be previewed in the preview panel, or all results can be saved to a file.

top

Running MartExplorer

MartExplorer can be started by running the script bin/martexplorer.bat or martexplorer.sh on windows and *nix OS repspectively.

top

Building and executing a query

When MartExplorer starts up the user is presented with a QueryEditor with some datasets to choose between. The first thing the user must do when building a query is select the dataset that the query is about.

Once the dataset is selected the user can select the attributes, filters and output format. The attribute panel is shown first but the user can switch to the filter or format panels by clicking on the Filters or Format items in the tree. The user can return to the attributes page by clicking the Attributes item in the tree.

Once the user has built the query it can be run in one of two ways. It can be executed (Execute tool bar button or File -> Execute menu item) or the results can be saved (Save tool bar button or File -> Save / Save As menu items). Executing the query causes a preview of the results to be displayed in the in the preview panel while save results causes all the results to be written to a file specified by the user. Results for the query can be saved to different files by using the File -> Save As menu item.

Attributes and filters can also be removed, the attribute order changed and the output format altered. There are two ways to delete items: (a) select the item in the tree and then press delete, (b) Remove it using the appropriate input page; for attributes this is done by unchecking the check box for the attribute in the data entry area. The order of the attributes in the results corresponds to their order in the tree. This can be changed by dragging and dropping them in the tree. Finally, the format can be changed via the Format page which can be shown by clicking on Format in the tree.

Additional queries can be created by clicking the New query button or selecting the menu item File -> New Query. Conversely the currently selected query can be removed by with File -> Close Query and all queries by File -> Close All Queries.

top

Adding Mart Databases

It is possible to add new Mart databases in addition to the default ones already present when the application starts up. This can be done in two ways: by specifying an Mart Registry file and/or interactively during MartExplorer session. The former makes added databases available at a start up the latter only for the duration of the Mart Explorer session.

Registry file
At start up MartExplorer reads an registry file, which specifies a set mart databases. The defalut registry file is located in the data directory: defaultMartRegistry.xml. It is possible to overide its contents by placing a .userMartRegistry.xml file in the user's home directory. This must be a valid registry file. See the default file (data/defaultMartRegistry.xml) for an example and the documentation for more details. The easiest approach is to simply copy the defaultMartRegistry.xml to user home directory changing its name to .userMartRegistry.xml and edit the file according to one's requirements.

Interactively
Mart databases can also be added using the "Add Mart" settings window. This is opened with the menu item Settings -> Add Mart. This button opens the database connection window from which the user can specify mart database connection parameters. Once this is done the marts will be available for use in new queries. Note that some values are "pre-loaded" into the drop down lists that are available by pressing the small downward arrow at the end of each text entry box. This can save you typing the entries.

Enabling other Options

By selcting Settings -> Enable, a user may choose to enable extra options:

top