Free Software to Compare SQLite Databases and Tables: Sqldiff

Editor Ratings:
User Ratings:
[Total: 0 Average: 0]

Sqldiff.exe is a command-line utility program used to Display Differences in content between SQLite databases.

SQLite is written in the C language and is an embed-able SQL database engine. This utility reads & writes direct to a disk file and does not appear to have a dedicated server process. A complete SQLite database with multiple views, indices, tables, and more.

This utility works by detecting rows in the source and destination SQLite databases that are logically paired. Two rows are treated as pairs if they have the same ‘rowids’ and are in tables that have the same names. In case there is now defined ‘rowid’ then the logically paired if they have the same Primary Key. The content differences that are found in the ‘logically paired’ rows are defined as ‘updates’.

Command-line usage of SQLdiff.exe

Sqldiff chinook1.db chinook1.db

This command will transform the chinook.db (source) database file into chinook1.db (destination) file.

The default behavior on the execution of this command can be modified using the following switches

1. –changeset: Do not write or commit the changes. Instead the utility writes the binary changeset into the named file that can be interpreted using the SQLiite Session Extension. This extension provides a way to record changes to the tables in an SQLite database.

Sqldiff chinook1.db chinook1.db –changeset  <Name of file>


Changeset Output

2. –lib Library: This switch load the shared DLL named file into the SQLite engine before processing the differences between the two databases.

Sqldiff chinook1.db chinook1.db –lib <Name of DLL file>

3. –primarykey: Uses the primary key defined by the Database Schema. Every row in an SQLite database has a specially defined column called rowid that uniquely identifies that row within the table.

Sqldiff chinook1.db chinook1.db –primarykey

4. –schema: This switch displays only the differences in columns names and tables between the two SQLite databases

Sqldiff chinook1.db chinook1.db –schema

Schema switch

5. –summary: This switch displays number of changed rows in each table without displaying the actual changes in the rows.

Sqldiff chinook1.db chinook1.db –summary

Summary switch

6. –table: the entire database content difference is not showed, it will show named table content difference only.

Sqldiff chinook1.db chinook1.db –table <Name of Table>

Table switch

7. –transaction: the output is displayed as a large single transaction.

Sqldiff chinook1.db chinook1.db –transaction

Transaction switch

8. –vtab: This switch adds support for virtual tables like FTS5, rtree and FTS3. These are specialized table modules that provide full text search functionality to database applications

Sqldiff chinook1.db chinook1.db –vtab

Click here to download this command line utility and choose one of the precompiled binaries for Windows.

Editor Ratings:
User Ratings:
[Total: 0 Average: 0]
Free/Paid: Free

Leave A Reply


Get 100 GB FREE

Provide details to get this offer