I'd like to be able to get some debug output of what's actually being sent to the database, especially when using an ORM like Dapper. I suspect you could add some strategic Trace.Write calls before calling sqlite3.raw.
Putting this on the backlog. This should be done using DiagnosticSource/DiagnosticListener. These are the event APIs that are now being used across all .NET.
You can easily leverage SQLite's native tracing (via SQLitePCL.raw):
SQLitePCL.raw.sqlite3_trace(
connection.Handle,
(_, statement) => Trace.WriteLine(statement, "SQLite"),
null);
Thanks for the workaround - that'll help for now.
Commenting again after hitting another situation where this'd be useful. I can't seem to get the workaround to work in .NET Core - I suspect I'm doing something really silly because I can't get the SQLitePCL type to be found in VS2017.
Edit: I was using Microsoft.Data.Sqlite 1.1.1, it worked after upgrading to some preview (!) release in the 2.1.0 series.
Most helpful comment
Workaround
You can easily leverage SQLite's native tracing (via SQLitePCL.raw):