mirror of
https://github.com/nsnail/FreeSql.git
synced 2025-06-19 20:38:16 +08:00
- 修复 MySql 子查询 Enum MapType(int) 表达式判断解析 bug;#1118
This commit is contained in:
@ -648,7 +648,11 @@ namespace FreeSql.Internal
|
||||
{
|
||||
var enumType = leftMapColumn.CsType.NullableTypeOrThis();
|
||||
if (enumType.IsEnum)
|
||||
right = formatSql(Enum.Parse(enumType, right.StartsWith("N'") ? right.Substring(1).Trim('\'') : right.Trim('\'')), leftMapColumn.Attribute.MapType, leftMapColumn, tsc.dbParams);
|
||||
{
|
||||
rightMapColumn = SearchColumnByField(tsc._tables, tsc.currentTable, right);
|
||||
if (rightMapColumn != null)
|
||||
right = formatSql(Enum.Parse(enumType, right.StartsWith("N'") ? right.Substring(1).Trim('\'') : right.Trim('\'')), leftMapColumn.Attribute.MapType, leftMapColumn, tsc.dbParams);
|
||||
}
|
||||
}
|
||||
if (leftMapColumn == null)
|
||||
{
|
||||
|
Reference in New Issue
Block a user