internal class Table
{
public string COUNT { get; set; }
}
lock (DbBase.LockDb)
{
using (DbBase db = new DbBase())
{
Table Msg=null;
Msg = db.Conn.Query<Table>("select COUNT(*) from sqlite_master where [type]='table' and [name]=@name", new { name = "DBVersion" }).ToList().FirstOrDefault();
Console.Write(Msg.COUNT);
}
}
这写的不对嘛?怎么查询为空