SQLite Forum

Bug: sqldiff --changeset SOME_FILE ... produces 0-length file
(Refreshing and clarifying this bug report.)

Recently, I had reason to see what the "--changeset SOME_FILE" option to sqldiff actually does. [a] I ran the "stock" version, one I downloaded as "sqlite-tools-win32-x86-3340100.zip" [b], with this invocation:<code>
  sqldiff --changeset db_1-2_changeset db1.sdb db2.sdb
</code>, where the two .sdb files are different, confirmed by sqldiff's output when the --changeset option is omitted. The result is that db_1-2_changeset is created and left as an empty file. This is not what the [sqldiff doc](https://sqlite.org/sqldiff.html) indicates should happen. Hence, I believe this represents a sqldiff bug.

[a. I had been testing a local change to sqldiff.c and noticed that the subject invocation (with ... naming two, differing databases) produced an entirely empty "changeset" file. The change was to optionally specify some non-PK column(s) that will not participate in the value comparison.  It did not touch the changeset_one_table() function. Of course, wondering how I broke functionality I **tried** to not touch, I ran the "stock" version to see if I had created a bug. ]

[b. I tested sqldiff.exe on an up-to-date Windows 10 machine. ]

Is this 0-length changeset file creation, regardless of database differences, a known non-feature of sqldiff? If so, its doc is wrong. Otherwise this lack of output must be a bug.