Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
themeMidnight
languagebash
pg_dump -U username -h hostname -a --inserts filesender |
sed -r 's/^(INSERT\ INTO\ )(files|logs)(\ VALUES\ )/\1`\2`\3/g' |
grep --color=never "^INSERT INTO" |
sqlite3 filesender.sqlite

 

SQLite to MySQL

Code Block
themeMidnight
languagebash
sqlite3 filesender.sqlite .dump |
sed -r 's/^(INSERT\ INTO\ )"(logs|files)"(\ VALUES)/\1`\2`\3/g' |
grep --color=never "^INSERT INTO \`" |
mysql -u username -h hostname -p filesender