mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-09-19 10:08:19 +08:00
Update exp to sql
This commit is contained in:
@@ -584,7 +584,7 @@ namespace SqlSugar.MongoDb
|
||||
{
|
||||
lengthValue = UtilMethods.GetMemberName(lengthValue);
|
||||
}
|
||||
var substrDoc = new BsonDocument("$substrBytes", new BsonArray { GetMemberName(memberName), startValue, lengthValue });
|
||||
var substrDoc = new BsonDocument("$substrBytes", new BsonArray { GetMemberName(memberName,item), startValue, lengthValue });
|
||||
return substrDoc.ToJson(UtilMethods.GetJsonWriterSettings());
|
||||
}
|
||||
|
||||
@@ -778,7 +778,14 @@ namespace SqlSugar.MongoDb
|
||||
{
|
||||
return UtilMethods.GetMemberName(memberName);
|
||||
}
|
||||
|
||||
private static BsonValue GetMemberName(BsonValue memberName,Expression expression)
|
||||
{
|
||||
if (ExpressionTool.GetParameters(expression).Count > 0)
|
||||
{
|
||||
return UtilMethods.GetMemberName(memberName);
|
||||
}
|
||||
return memberName;
|
||||
}
|
||||
/// <summary>
|
||||
/// Converts a C# date format string to a MongoDB-compatible date format string.
|
||||
/// </summary>
|
||||
|
Reference in New Issue
Block a user