Database-Specific Troubleshooting

Solutions to issues specific to particular database platforms.

Overview

Each database platform has unique characteristics and potential issues:

  • PostgreSQL-specific problems

  • MySQL/MariaDB issues

  • Oracle Database concerns

  • SQL Server challenges

PostgreSQL

Schema Search Path

Issue: Tables not found despite correct names.

Solution: Set search path explicitly:

data_sources:
  input:
    url: jdbc:postgresql://host:5432/db?currentSchema=public,schema1,schema2

Large Object Support

Issue: BLOB/CLOB handling errors.

Solution: Adjust LO (Large Object) settings:

url: jdbc:postgresql://host:5432/db?ApplicationName=TDK&lobMode=on

MySQL

max_allowed_packet

Issue: "Packet too large" errors.

Solution: Increase packet size:

SET GLOBAL max_allowed_packet=1073741824;  -- 1GB

ENUM Types

Issue: ENUM values not preserved correctly.

Solution: Use Categorical transformer:

transformations:
  - columns: ["status"]
    type: Categorical

Oracle

ORA-00001: Unique Constraint Violated

Issue: Sequence values conflict with existing data.

Solution: Reset sequences before generation:

-- Reset sequence
ALTER SEQUENCE customer_seq RESTART WITH 10000;

TNS Configuration

Issue: "TNS: could not resolve connect identifier".

Solution: Verify tnsnames.ora and set TNS_ADMIN:

export TNS_ADMIN=/path/to/tnsnames.ora

SQL Server

Identity Columns

Issue: Cannot insert into IDENTITY columns.

Solution: TDK handles this automatically, but verify:

-- Check IDENTITY columns
SELECT name, is_identity
FROM sys.columns
WHERE object_id = OBJECT_ID('dbo.customers');

Collation Issues

Issue: Comparison or sorting errors.

Solution: Specify collation in connection string:

url: jdbc:sqlserver://host:1433;database=db;collation=SQL_Latin1_General_CP1_CI_AS