Converts any uppercase characters in a CHARACTER or LONGCHAR expression to lowercase characters, and returns the result. The data type of the returned value matches the data type of the expression passed to the function.
Syntax
LC ( expression )
expression
A constant, field name, variable name, or expression that results in a CHARACTER or LONGCHAR value.
Example
This procedure finds a Customer record. After the user updates the SalesRep field, the procedure converts the first character of the SalesRep value to uppercase and the remaining characters to lowercase.
The CAPS function uses the SUBSTRING function to extract the first character of the field, which it then converts to uppercase.
In the LC function, the result of the SUBSTRING function is the remaining characters in the SalesRep field, starting with character position 2. (No length is specified, so the remainder of the string is assumed). The LC function converts these characters to lowercase.
Notes
The LC function returns lowercase characters relative to the settings of the Internal Code Page (-cpinternal) and Case Table (-cpcase) startup parameters. For more information on these parameters, see OpenEdge Deployment: Startup Command and Parameter Reference.
The LC function is double-byte enabled. The specified expression can yield a string containing double-byte characters; however, the LC function changes only single-byte characters in the string.