Configuration

Config file reference — TOML (preferred) or YAML.

Minimum Configuration

The smallest config file that works — all other sections are optional and will use sensible defaults:

# replicatorconfig.toml
[DAO]
database = "C:\\Users\\you\\MyData.accdb"

[postgresql]
host = "localhost"
port = 5432
database = "replicated_db"
user = "replicator"
password = "your-password"

Global Settings

[global]
batch_size = 1000   # Rows per INSERT batch (default: 1000)

Table Selection

By default, Replicator-NG auto-discovers all non-system tables. You can restrict or exclude:

# Only replicate these tables
tables = ["Customers", "Orders", "Products"]

# Exclude these tables
excluded = ["TempData", "Archive_2023"]

Nonvolatile Tables

Tables that rarely change. The replicator skips them when row counts match:

nonvolatile = ["PostalCodes", "ProductCategories", "Regions"]

Primary Key Overrides

If Access doesn't declare a primary key but you know one exists:

[[primarykeys]]
table = "OrderHistory"
columns = ["OrderID", "LineNumber"]

Foreign Keys

Auto-discovered from Access relationships. Add manual FKs if needed:

[[foreignkeys]]
table = "Orders"
column = "CustomerID"
references = "Customers.CustomerID"

Column Transformations

Transform data during replication. Each transform targets a specific table and column:

[[transformations]]
table = "Customers"
column = "LastName"
transform = "uppercase"

[[transformations]]
table = "Products"
column = "StartDate"
transform = "YearOnly"

[[transformations]]
table = "Orders"
column = "Notes"
transform = "trim"
TransformEffect
uppercaseConvert to UPPERCASE
lowercaseConvert to lowercase
trimRemove leading/trailing whitespace
regex_replaceRegex substitution (needs params)
null_to_defaultReplace empty values with a default (needs params)
type_coerceForce a specific type conversion
YearOnlyExtract year from date → YYYY-01-01
DROPRemove the column entirely from the replica
🖥️ GUI users: The Column Transformations panel provides dropdown selectors for Table → Column → Type — no manual YAML/TOML editing needed.

Save & Load

Config files use .toml or .yaml extension. The format is auto-detected:

The GUI's 💾 Save Config and 📂 Load Config buttons handle both formats. On launch, it auto-loads replicatorconfig.toml if present.