Metadata-Version: 2.1
Name: mysql-to-sqlite3
Version: 1.3.4
Summary: A simple Python tool to transfer data from MySQL to SQLite 3
Home-page: https://github.com/techouse/mysql-to-sqlite3
Author: Klemen Tusar
Author-email: techouse@gmail.com
License: MIT
Project-URL: Source, https://github.com/techouse/mysql-to-sqlite3
Platform: UNKNOWN
Classifier: Development Status :: 5 - Production/Stable
Classifier: Environment :: Console
Classifier: Intended Audience :: End Users/Desktop
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: System Administrators
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 2
Classifier: Programming Language :: Python :: 2.7
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.5
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: 3.7
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Topic :: Database
Requires-Python: >=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*
Description-Content-Type: text/markdown
Requires-Dist: Click (>=7.0)
Requires-Dist: mysql-connector-python (>=8.0.18)
Requires-Dist: pytimeparse (>=1.1.8)
Requires-Dist: python-slugify (>=3.0.3)
Requires-Dist: simplejson (>=3.16.0)
Requires-Dist: six (>=1.12.0)
Requires-Dist: tqdm (>=4.35.0)
Requires-Dist: tabulate

[![PyPI](https://img.shields.io/pypi/v/mysql-to-sqlite3)](https://pypi.org/project/mysql-to-sqlite3/)
[![Downloads](https://pepy.tech/badge/mysql-to-sqlite3)](https://pepy.tech/project/mysql-to-sqlite3)
[![PyPI - Python Version](https://img.shields.io/pypi/pyversions/mysql-to-sqlite3)](https://pypi.org/project/mysql-to-sqlite3/)
[![MySQL Support](https://img.shields.io/static/v1?label=MySQL&message=5.5+|+5.6+|+5.7+|+8.0&color=2b5d80)](https://img.shields.io/static/v1?label=MySQL&message=5.6+|+5.7+|+8.0&color=2b5d80)
[![MariaDB Support](https://img.shields.io/static/v1?label=MariaDB&message=5.5+|+10.0+|+10.1+|+10.2+|+10.3+|+10.4+|+10.5&color=C0765A)](https://img.shields.io/static/v1?label=MariaDB&message=10.0+|+10.1+|+10.2+|+10.3+|+10.4+|+10.5&color=C0765A)
[![GitHub license](https://img.shields.io/github/license/techouse/mysql-to-sqlite3)](https://github.com/techouse/mysql-to-sqlite3/blob/master/LICENSE)
[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/ambv/black)
[![Codacy Badge](https://api.codacy.com/project/badge/Grade/64aae8e9599746d58d277852b35cc2bd)](https://www.codacy.com/manual/techouse/mysql-to-sqlite3?utm_source=github.com&amp;utm_medium=referral&amp;utm_content=techouse/mysql-to-sqlite3&amp;utm_campaign=Badge_Grade)
[![Build Status](https://travis-ci.com/techouse/mysql-to-sqlite3.svg?branch=master)](https://travis-ci.com/techouse/mysql-to-sqlite3)
[![codecov](https://codecov.io/gh/techouse/mysql-to-sqlite3/branch/master/graph/badge.svg)](https://codecov.io/gh/techouse/mysql-to-sqlite3)
[![GitHub stars](https://img.shields.io/github/stars/techouse/mysql-to-sqlite3.svg?style=social&label=Star&maxAge=2592000)](https://github.com/techouse/mysql-to-sqlite3/stargazers)


# MySQL to SQLite3

#### A simple Python tool to transfer data from MySQL to SQLite 3.

This is the long overdue complimentary tool to my [SQLite3 to MySQL](https://github.com/techouse/sqlite3-to-mysql). It 
transfers all data from a MySQL database to a SQLite3 database.

### How to run

```bash
pip install mysql-to-sqlite3
mysql2sqlite --help
```

### Usage
```
Usage: mysql2sqlite [OPTIONS]

  Transfer MySQL to SQLite using the provided CLI options.

Options:
  -f, --sqlite-file PATH      SQLite3 database file  [required]
  -d, --mysql-database TEXT   MySQL database name  [required]
  -u, --mysql-user TEXT       MySQL user  [required]
  -p, --mysql-password TEXT   MySQL password
  -t, --mysql-tables TEXT     Transfer only these specific tables (space
                              separated table names). Implies --without-
                              foreign-keys which inhibits the transfer of
                              foreign keys.

  -X, --without-foreign-keys  Do not transfer foreign keys.
  -h, --mysql-host TEXT       MySQL host. Defaults to localhost.
  -P, --mysql-port INTEGER    MySQL port. Defaults to 3306.
  -c, --chunk INTEGER         Chunk reading/writing SQL records
  -l, --log-file PATH         Log file
  -V, --vacuum                Use the VACUUM command to rebuild the SQLite
                              database file, repacking it into a minimal
                              amount of disk space

  --use-buffered-cursors      Use MySQLCursorBuffered for reading the MySQL
                              database. This can be useful in situations where
                              multiple queries, with small result sets, need
                              to be combined or computed with each other.

  -q, --quiet                 Quiet. Display only errors.
  --version                   Show the version and exit.
  --help                      Show this message and exit.
```

