Last updated on
Description
Gets a specified number of characters from a string, beginning at the right.Returns the specified number of characters from the end (or right side) of the specified string.
Returns
- If the length of the string is greater than or equal to count, the rightmost count characters of the string
- If count is greater than the length of the string, the whole string
- If count is greater than 1, and the string is empty, an empty string
Category
Function syntax
Right(string, count)
<cfscript> string="The quick brown fox jumps over the lazy dog" count=8 writeOutput(Right(string,count)) // lazy dog </cfscript>