Difference between revisions of "Migrating a database from mysql to sqlite"
From Linuxintro
imported>ThorstenStaerk |
imported>ThorstenStaerk |
||
Line 1: | Line 1: | ||
+ | I tried to migrate my wiki's database from MySQL to SQLite. To do this | ||
+ | * I created a dump (aka backup aka export) of the database | ||
mysqldump wikidb -u wikiuser -p > dump.sql | mysqldump wikidb -u wikiuser -p > dump.sql | ||
− | + | * I got a MySQL -> SQLite converter | |
− | https://gist.github.com/esperlu/943776/ | + | wget https://gist.github.com/esperlu/943776/raw/dd87f4088f6d5ec7563478f7a28a37ba02cf26e2/mysql2sqlite.sh |
+ | * I started this converter | ||
+ | sh mysql2sqlite.sh -u wikiuser -p wikidb | sqlite test.sqlite | ||
= See also = | = See also = | ||
* [[migrating mediawiki from mysql to sqlite]] | * [[migrating mediawiki from mysql to sqlite]] |
Revision as of 12:47, 7 September 2013
I tried to migrate my wiki's database from MySQL to SQLite. To do this
- I created a dump (aka backup aka export) of the database
mysqldump wikidb -u wikiuser -p > dump.sql
- I got a MySQL -> SQLite converter
wget https://gist.github.com/esperlu/943776/raw/dd87f4088f6d5ec7563478f7a28a37ba02cf26e2/mysql2sqlite.sh
- I started this converter
sh mysql2sqlite.sh -u wikiuser -p wikidb | sqlite test.sqlite