- 修复 Firebird Embedded 版本系统表 isidentity_type 兼容问题;

This commit is contained in:
28810
2020-10-18 19:23:13 +08:00
parent 0783b432cf
commit b91fe2ca4d
3 changed files with 30 additions and 7 deletions

View File

@ -35,6 +35,29 @@ namespace FreeSql.Firebird
}
}
}
public bool IsFirebird2_5 => ServerVersion.Contains("Firebird 2.5");
public string ServerVersion
{
get
{
if (string.IsNullOrEmpty(_serverVersion) && MasterPool != null)
using (var conn = MasterPool.Get())
{
try
{
_serverVersion = conn.Value.ServerVersion;
}
catch
{
_serverVersion = "3.0.0";
}
}
return _serverVersion;
}
}
string _serverVersion;
public override object AddslashesProcessParam(object param, Type mapType, ColumnInfo mapColumn)
{
if (param == null) return "NULL";