LENV: Returning the Length of an Alphanumeric Field

How to:

LENV returns the actual length of an AnV field or the size of an An field.

Syntax: How to Find the Length of an Alphanumeric Field

LENV(source_string, output)

where:

source_string

Alphanumeric of type An or AnV

Is the source string or field. If it is an An format field, the function returns its size, n. For a character string enclosed in quotation marks or a variable, the size of the string or variable is returned. For a field of AnV format, its length, taken from the length-in-bytes of the field, is returned.

output

Integer

Example: Finding the Length of an AnV Field

WebFOCUS

Feedback