Share via


EdmFunctions.Trim(DbExpression) 方法

定义

创建一个 DbFunctionExpression,它调用具有指定参数的规范“Trim”函数,其必须具有字符串结果类型。 该表达式的结果类型也为字符串。

public:
[System::Runtime::CompilerServices::Extension]
 static System::Data::Common::CommandTrees::DbFunctionExpression ^ Trim(System::Data::Common::CommandTrees::DbExpression ^ stringArgument);
public static System.Data.Common.CommandTrees.DbFunctionExpression Trim (this System.Data.Common.CommandTrees.DbExpression stringArgument);
static member Trim : System.Data.Common.CommandTrees.DbExpression -> System.Data.Common.CommandTrees.DbFunctionExpression
<Extension()>
Public Function Trim (stringArgument As DbExpression) As DbFunctionExpression

参数

stringArgument
DbExpression

一个表达式,该表达式指定应从中删除先导空格和尾随空格的字符串。

返回

一个新的 DbFunctionExpression,它返回 的值 stringArgument ,并删除了前导空格和尾随空格。

例外

stringArgumentnull

stringArgument 无效。

适用于