Update 达梦

This commit is contained in:
sunkaixuan 2024-12-10 12:34:02 +08:00
parent 8cc07617d3
commit f2f254d0cc
2 changed files with 11 additions and 1 deletions

View File

@ -2,7 +2,7 @@
<package > <package >
<metadata> <metadata>
<id>SqlSugar.XuguCoreNew</id> <id>SqlSugar.XuguCoreNew</id>
<version>5.1.4.173</version> <version>5.1.4.174</version>
<authors>sunkaixuan</authors> <authors>sunkaixuan</authors>
<owners>果糖大数据</owners> <owners>果糖大数据</owners>
<licenseUrl>http://www.apache.org/licenses/LICENSE-2.0.html</licenseUrl> <licenseUrl>http://www.apache.org/licenses/LICENSE-2.0.html</licenseUrl>

View File

@ -183,10 +183,20 @@ namespace SqlSugar
{ {
sqlParameter.DmSqlType = DmDbType.Cursor; sqlParameter.DmSqlType = DmDbType.Cursor;
} }
if (IsSpOutPutParameter(sqlParameter))
{
sqlParameter.ParameterName = sqlParameter.ParameterName.Replace("@", ":");
}
++index; ++index;
} }
return result; return result;
} }
private bool IsSpOutPutParameter(DmParameter sqlParameter)
{
return sqlParameter.Direction == ParameterDirection.Output && this.CommandType == CommandType.StoredProcedure;
}
private static string[] KeyWord =new string []{ "@month", ":month", ":day","@day","@group", ":group",":index", "@index", "@order", ":order", "@user", "@level", ":user", ":level",":type","@type", ":year", "@year" }; private static string[] KeyWord =new string []{ "@month", ":month", ":day","@day","@group", ":group",":index", "@index", "@order", ":order", "@user", "@level", ":user", ":level",":type","@type", ":year", "@year" };
private static string ReplaceKeyWordParameterName(string sql, SugarParameter[] parameters) private static string ReplaceKeyWordParameterName(string sql, SugarParameter[] parameters)
{ {