1 .. mysql2sql documentation master file, created by
2 sphinx-quickstart on Fri Jul 22 19:32:24 2016.
3 You can adapt this file completely to your liking, but it should at least
4 contain the root `toctree` directive.
6 Welcome to mysql2sql's documentation!
7 =====================================
9 This is mysql2sql, a mysql to sql converter. It is primary intended to
10 convert mysqldump (especially with extended INSERT syntax) to standard
11 SQL to load at least to PostgreSQL or SQLite.
13 It uses `sqlparse <https://github.com/andialbrecht/sqlparse>`_ to parse
16 The program is in its initial phase and currently cannot do much.
28 mysql2sql [-e encoding] [-E output_encoding] [infile] [[-o] outfile]
32 -e ENCODING, --encoding ENCODING
33 input/output encoding, default is utf-8
34 -E OUTPUT_ENCODING, --output-encoding OUTPUT_ENCODING
35 separate output encoding, default is the same as
36 `-e` except for console; for console output charset
37 from the current locale is used
38 -P, --no-pbar Inhibit progress bar
39 infile Input file, stdin if absent or '-'
40 -o, --outfile outfile Output file, stdout if absent or '-'
42 If stderr is connected to the console the program displays a text mode progress
43 bar. Option `-P/--no-pbar` inhibits it.
45 Option `-o` is useful when infile is absent (input is redirected), for
48 mysql2sql -o outfile.sql < infile.sql
49 cat infile.sql | mysql2sql -o outfile.sql
51 But of course it simply can be::
53 mysql2sql - outfile.sql < infile.sql
54 cat infile.sql | mysql2sql - outfile.sql
61 * `<api/modules.html>`_
68 Created by Oleg Broytman <phd@phdru.name>.
70 Copyright (C) 2016 PhiloSoft Design.