62,046
社区成员
发帖
与我相关
我的任务
分享
public class SqlSugarHelper
{
public static SqlSugarClient DB { get; set; }
public SqlSugarHelper()
{
DB=new SqlSugarClient(new ConnectionConfig()
{
ConnectionString = @"xxxxx",//必填, 数据库连接字符串
DbType = DbType.Oracle, //必填, 数据库类型
IsAutoCloseConnection = true, //默认false, 时候知道关闭数据库连接, 设置为true无需使用using或者Close操作
InitKeyType = InitKeyType.SystemTable //默认SystemTable, 字段信息读取, 如:该属性是不是主键,是不是标识列等等信息
});
}
}