Populating the Database

Once the database is set up you can begin to populate it with election data. There are two means of inserting the data - manually with the Inserter and automatically using the Importer.

Inserting

Add New Election

If the database has just been created then the first task is to insert a new election.  The add new election dialogue is invoked by the selecting the menu Tools - > Insert -> New Election.

Add New Election

Provide the following details for the new election: Select OK to insert the new election into the database.

Add New Candidate

A new candidate can be inserted into the database by using the Insert New Candidate dialog - Tools - > Insert -> New Candidate

Add New Candidate

Give the new candidate a first and surname, select a party and press Apply or OK.

Note: currently the populating of the Party table is a manual task - this will be added in a future release.

Inserter

The Inserter is a tool for manually inserting results into the database.   It is invoked by right-clicking on the constituency (from the Constituency Tree) you wish to insert the result into and select Add Result.

The Inserter

The upper level of the display show the most recent result for this constituency (if one exists).
The centre section contains the widgets for inserting a new result and navigating previous results of the same constituency.

Note: if the election is a List election then the above dialogue will differ in that the election participant will be a party instead of a candidate.

To insert a new result:

Add Party Leader

For each election, a total vote is calculated and displayed under the nation tree node.  The candidate's name for this overall result is the party leader.  The party leader can be defined using the Add Party Leader dialogue - Tools -> Insert  -> Party Leader.


Add Party Leader


The dialogue displays a list of current defined leaders for the currently selected election.  Using the Candidate Selector dialogue (Find Candidate) you can add another leader to the election.  If the election is a local election, you will have the additional step of selecting the council.

Candidate Selector

The candidate selector dialogue is a utility dialogue used by a number of screens for selecting candidates in an election.

Candidate Selector

It displays all candidates in the database alphabetically with the candidate's party abbreviation.  A seach field dynamically filters for the pattern inserted into the field.  The dialogue also has the ability to insert new candidates using the Add New Candidate dialogue.

Importing

The importer populates the database automatically from comma separated files (typically exported from a spreadsheet) containing the election data.
The files must contain the following information about each election entry:

Configuration

The following properties are defined in the <gswing_home>/etc/properties.cfg file to tell the importer where in the CSV file to find each column. To invoke the importer use the Tools -> Importer option

You will be presented with the following options:

Create XML from CSV.

Import from XML


Constituency Tree  Home   Exporting