.
Skip Navigation Links
Home
CyberTrackerExpand CyberTracker
Portfolio
Contact

CyberTracker Server Setup

Background

A CyberTracker database is normally a Microsoft Access database or .MDB file. This is convenient because a single file can hold the entire database. However, only one user can connect at a time and the database size is limited to 2 GB.  

CyberTracker supports connections to Server databases such as MySQL and Microsoft SQL Server. This is done using a connection file, which tells CyberTracker how to communicate with the server.

Installing and configuring MySQL

Download and install MySQL from http://dev.mysql.com/downloads/mysql/5.0.html.
Version 5.1 is recommended.
Add the following line to \MySQL\MySQL Server 5.1\my.ini:

max_allowed_packet = 64M

Download and install MySQL Connector from http://dev.mysql.com/downloads/connector/odbc/5.1.html.

Creating a connection

CyberTracker supports connecting to a database via an EDB (External Database) file. An EDB file is an XML file that tells CyberTracker how to connect to the database. Here is an example EDB file:

<?xml version="1.0" encoding="UTF-8"?>
<Database>
    <TypeRules>MySQL</TypeRules>
    <ConnectionString>
        Provider=MSDASQL.1;
        User ID=root;
        Password=root;
        Persist Security Info=True;
        Data Source=MySQL DataSource;
        Initial Catalog=MyDatabaseName
    </ConnectionString>
</Database>

TypeRules specifies how to treat data types. Acceptable values are "MySQL" and "SQL Server". This is to handle differences in SQL database types.

User ID and Password should be set according to your credentials.

Data Source is the name of a User Data Source as configured by the windows "ODBC Data Source Administrator". This tool binds a database driver to a data source so that applications can access it easily. The tool can be run by using Start->Run and typing "odbcad32.exe". Make sure that an ODBC driver is available for your database before setting this up. For MySQL, this is the MySQL Connector.

Initial Catalog is the name of the database. This database can be created using the "CREATE DATABASE MyDatabaseName" SQL command.  

Converting an existing database

Once you can successfully connect to the server database by opening the .EDB file (using File->Open from the CyberTracker main menu), the next step is to import an existing database. The most common way to do this is:

  • Load the old MDB database, using File->Open
  • Export it to a CTX file, using File->Export
  • Open the new EDB database, using File->Open
  • Import the CTX file, using File->Import
  • Save the new database

Multiple simultaneous connections

By distributing the EDB file within your organization, multiple users can connect to the database simultanously. This has 2 implications to be aware of:

  1. As new sightings come in from remote sources, users will need to press "F5" (or use Edit->Refresh) to see new sightings
  2. Conflicts may arise if multiple users are making changes to the same database. To restrict this, end-users should not use the "Studio" version when viewing data. In all cases, the most recently saved data wins.

Using Export Data Tables

An Export Data Table is a table in a database that holds captured sighting data in an exported tabular form.

In order to view sighting data within CyberTracker, it is 'projected' onto a table. This simply means that each sighting attribute is mapped to a column. This table is a very natural way to view and query the data.

CyberTracker has the ability to export the Query View table to a database table. However, doing this requires some setup: the table must already be created in the target database and must have certain pre-defined fields.

To get started, create a table in your database named "Export" with the following SQL command:

CREATE TABLE Export (ID CHAR(38) NOT NULL UNIQUE, Date DATE, Time TIME, Latitude DOUBLE, LONGITUDE DOUBLE, Note LONGTEXT)

  1.  Load CyberTracker and open a report with sightings
  2. With the Query Editor selected, click on the "Export View" button
  3.  In the "Save As Type" drop down, select "External database" and select the database you want to export to
  4.  Click Okay. Note you will get a message about overwriting this file, but it can be ignored (the .EDB file will not be overwritten, but duplicate data in the "Export" table will be)

 Finally, use the following SQL command to see the data in the "Export" table in the database:

SELECT * FROM Export

Here is the list of field names (and their associated types) which CyberTracker recognizes specially:

Id CHAR(38) NOT NULL UNIQUE The primary Id of the sighting. This must be indexed for merging reasons.
DeviceId CHAR(38) The Id of the device used to capture the observation. This can be used to group sightings created by a single observer.
Deleted SMALLINT Whether or not the sighting has been deleted. Using this field allows deleted sightings to be correctly merged.

The UI component of this feature is designed mainly for experimentation. It can be more fully controlled via the CyberTracker Command-Line.

CyberTracker matches fields by name, so the column name in CyberTracker must be the same as the field name in the table to work correctly. Column names can be changed using the "View Properties" dialog.