/// <summary> /// 检查表是否存在 /// </summary> /// <param name="file"></param> /// <param name="tablename"></param> /// <returns></returns> public bool TableIsExist(string file, string tablename) { try { SqliteContext context = new SqliteContext(file); return(context.Exist(tablename)); } catch (Exception ex) { Console.WriteLine(string.Format("SQL查询失败", file, ex.Message)); throw; } }