- The target database has the right schema, tables, etc, and is empty. See the create scripts in the
- Both the source and destination database are called filesender
- SQLite databases are called filesender.sqlite
Postgres to MySQL
Use a shell script that does:
- Quote field names with backticks
- Remote any SET statements
- Remove any SELECT pg_catalog.setval statements
- Feed INSERT statements into MySQL
You can't simply filter all lines that start with INSERT INTO because the data contains newlines itself.
PostgreSQL to SQLite
Largely the same shell script, but no backticks are needed here.
This takes a while depending on the amount of records.
SQLite to PostgreSQL
SQLite to MySQL
MySQL to PostgreSQL