OperationsCommander - https://opscom.wiki

Using the Database Importer (Beta)

The Database Importer provides administrators with a powerful tool to import bulk data into the system using CSV files. Its primary purpose is to facilitate initial data migrations, execute mass record updates, and integrate data from external systems to ensure your database is populated efficiently. This article is intended for OPS-COM administrators responsible for backend data management.

Setup and Configuration

This feature requires specific administrative permissions to access and operate the import tools.

Admin Side: Administrators must have the appropriate permissions enabled under the Systems tab of the permissions management page. For complete instructions on modifying user access, refer to the Manage Roles and Permissions wiki article.

Using this Feature

Administrators can use the following instructions to upload CSV files, match data columns, and initiate the import process.

Accessing the Importer

  1. Hover over Tools and click Data Importer - BETA to access the main management screen.

Importing Data into a Table

  1. Click the Upload button next to the desired destination table.

  2. Select your comma-differentiated or semi-colon-differentiated CSV file from the modal window.

  3. Click the Submit button to begin the file upload and proceed to the table import screen.

  4. Match the columns from your imported CSV file to the corresponding destination columns within the system. The system will automatically pre-select matches if your CSV contains recognized column names.

  5. Click the Process button to initiate the background import process.

The importer has a strict limit of 10,000 records per batch import. This maximum count includes your CSV header row.

Resetting a Table

The Database Importer also allows administrators to completely purge an entire table's contents.

  1. Click the Reset button next to the specific table you wish to empty.

  2. Type DELETE into the confirmation text field in the modal window.

  3. Click the Delete button to permanently purge all records from the selected table.

Resetting a table is an irreversible, permanent action. Once the data is deleted, it cannot be recovered. Additionally, purging primary tables (like vehicles or permits) will automatically purge closely connected join tables (like vehicle joins or permit joins).

Order of Operations for Related Imports

Imports that contain related information must generally be executed in a specific order to ensure dependencies are met and records associate correctly.

Table to Import Requires Prior Import Notes
UserProfile None This should generally be the first table imported.
Vehicles UserProfile Ensures the user record exists so the vehicle can associate via a join record.
OffenceLocations None Must be imported prior to violations for proper location marking.
Permits Vehicles, UserProfile Ensures vehicle and user records exist for permit associations and automated payment marking.
Violations Vehicles, UserProfile, OffenceLocations A violation requires an existing vehicle record to be created, and an existing location to be marked properly.

Unique Identifiers and Duplicate Settings

When importing data, the system uses specific unique identifier columns to determine if a record already exists. If a match is found, the system will follow your selected duplicate setting to either ignore the duplicate (do nothing) or overwrite the existing record with the new CSV data.

Inserting Into Table Column Inserting Into Sourced From Table
UserProfile prov Provinces
UserProfile UserTypeID UserTypes
Vehicle ProvID Provinces
Vehicle ColourID VehicleColours
Vehicle MakeID VehicleMake
Vehicle TypeID VehicleType
Vehicle PlateTypeID VehiclePlateType
Permits LotNameID LotName
Permits StateID PermitState
Violations VehicleID Vehicle
Violations TicketType TicketCategory
Violations LocationID OffenceLocations

Understanding Post Import Processing

After data is inserted into the base table, the system runs separate, automated post-processing to establish relationships.


Best Practices and Considerations


Take Command of Your Parking and Security - https://OperationsCommander.com

Revision #24
Created 30 April 2024 08:04:21
Updated 13 July 2026 09:29:22