EntityFunctions.Left Method (String, Nullable<Int64>)
When used as part of a LINQ to Entities query, this method invokes the canonical Left EDM function to return a given number of the leftmost characters in a string.
Assembly: EntityFramework (in EntityFramework.dll)
[SuppressMessageAttribute("Microsoft.Naming", "CA1720:IdentifiersShouldNotContainTypeNames", MessageId = "string")] [SuppressMessageAttribute("Microsoft.Usage", "CA1801:ReviewUnusedParameters", MessageId = "length")] [DbFunctionAttribute("Edm", "Left")] [SuppressMessageAttribute("Microsoft.Usage", "CA1801:ReviewUnusedParameters", MessageId = "stringArgument")] public static string Left( string stringArgument, Nullable<long> length )
Parameters
- stringArgument
-
Type:
System.String
The input string.
- length
-
Type:
System.Nullable<Int64>
The number of characters to return
Return Value
Type: System.StringA string containing the number of characters asked for from the left of the input string.
You cannot call this function directly. This function can only appear within a LINQ to Entities query. This function is translated to a corresponding function in the database.