How to compare two SQLite databases on Linux

后端 未结 5 927
甜味超标
甜味超标 2020-12-13 05:42

Using Linux, I want to compare two SQLite databases that have the same schema. There will be just a few differences.

Is there a tool that would output these differen

5条回答
  •  情歌与酒
    2020-12-13 06:31

    One possibility is to use the sqlite3 command line client to export both databases and then diff the output. For example,

    sqlite3 first.sqlite .dump >first.dump
    sqlite3 second.sqlite .dump >second.dump
    diff first.dump second.dump
    

提交回复
热议问题