I am writing a custom PRAGMA to my SQLite db file using the below code:
using (var db = GetNewConnection())
{
var version = "1234";
var query = string.Format("PRAGMA user_version={0}", version);
db.ExecuteSql(query);
}
Which successfully writes the PRAGMA to the file and I can check that using SQLite Expert or LINQPad by executing:
PRAGMA user_version
But how can I read the value of PRAGMA from the DB file using OrmLite v3.9.71?
I have tried the below but it fails to parse the SQL as it can't find a "FROM":
db.Select<object>("PRAGMA user_version");
I have also tried the below, none of them work:
db.Select<dynamic>("PRAGMA user_version");
db.Select<string>("PRAGMA user_version");
db.Select<int>("PRAGMA user_version");
Any ideas?