分支自 SuZhouGuanHong/TaiYuanTaiZhong

PCS
dengjunjie
2023-12-13 113d1d4262d8f9e78a9d92123713c41669ad6c87
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
using System;
using System.Collections.Generic;
using System.Text;
using WIDESEA_Core.Configuration;
using WIDESEA_Core.Dapper;
using WIDESEA_Core.Enums;
 
namespace WIDESEA_Core.DBManager.Partial
{
    /// <summary>
    /// 2022.11.21增加其他数据库(sqlserver、mysql、pgsql、oracle)连接配置说明
    /// 需要把两个DBServerProvider.cs文件都更新下
    /// </summary>
    public partial class DBServerProvider
    {
        ///// <summary>
        ///// 单独配置mysql数据库
        ///// </summary>
        //public static ISqlDapper SqlDapperMySql
        //{
        //    get
        //    {
        //        //读取appsettings.json中的配置
        //        string 数据库连接字符串 = AppSetting.GetSettingString("key");
        //        return new SqlDapper(数据库连接字符串, DbCurrentType.MySql);
 
        //        //访问数据库方式
        //        //DBServerProvider.SqlDapperMySql.xx
        //    }
        //}
 
 
        ///// <summary>
        ///// 如果有多个不同的mysql数据库,这里再加一个配置
        ///// </summary>
        //public static ISqlDapper SqlDapperMySql2
        //{
        //    get
        //    {
        //        //读取appsettings.json中的配置
        //        string 数据库连接字符串 = AppSetting.GetSettingString("key2");
        //        return new SqlDapper(数据库连接字符串, DbCurrentType.MySql);
 
        //        //访问数据库方式
        //        //DBServerProvider.SqlDapperMySql2.xx
        //    }
        //}
 
        ///// <summary>
        ///// 单独配置SqlServer数据库
        ///// </summary>
        //public static ISqlDapper SqlDapperSqlServer
        //{
        //    get
        //    {
        //        //读取appsettings.json中的配置
        //        string 数据库连接字符串 = AppSetting.GetSettingString("key");
        //        return new SqlDapper(数据库连接字符串, DbCurrentType.MsSql);
 
        //        //访问数据库方式
        //        //DBServerProvider.SqlDapperSqlServer.xx
        //    }
        //}
    }
}