]> git.phdru.name Git - sqlconvert.git/blob - docs/index.rst
356f1d124872edffef16db48578a1a497ff03764
[sqlconvert.git] / docs / index.rst
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.
5
6 Welcome to mysql2sql's documentation!
7 =====================================
8
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.
12
13 It uses `sqlparse <https://github.com/andialbrecht/sqlparse>`_ to parse
14 SQL.
15
16 The program is in its initial phase and currently cannot do much.
17
18 .. highlight:: none
19
20 Command line
21 ------------
22
23 mysql-to-sql.py
24 ~~~~~~~~~~~~~~~
25
26 Usage::
27
28     mysql-to-sql.py [infile] [[-o] outfile]
29
30 Options::
31
32     infile                 Input file, stdin if absent or '-'
33     -o, --outfile outfile  Output file, stdout if absent or '-'
34
35 Option `-o` is useful when infile is absent (input is redirected), for
36 example::
37
38     mysql-to-sql.py -o outfile.sql < infile.sql
39     cat infile.sql | mysql-to-sql.py -o outfile.sql
40
41 But of course it simple can be::
42
43     mysql-to-sql.py - outfile.sql < infile.sql
44     cat infile.sql | mysql-to-sql.py - outfile.sql
45
46
47 Indices and tables
48 ==================
49
50 * :ref:`genindex`
51 * `<api/modules.html>`_
52 * :ref:`search`
53
54
55 Credits
56 =======
57
58 Created by Oleg Broytman <phd@phdru.name>.
59
60 Copyright (C) 2016 PhiloSoft Design.
61
62
63 License
64 =======
65
66 GPL.