Difference between revisions of "Manuals/calci/RIGHT"
(Created page with "<div id="6SpaceContent" class="zcontent" align="left"> <font color="#484848"><font face="Arial, sans-serif"><font size="2">'''RIGHT'''</font></font></font><font color="#484...") |
|||
| (3 intermediate revisions by the same user not shown) | |||
| Line 1: | Line 1: | ||
| − | + | =RIGHT(Text, Number_chars)= | |
| − | + | where, | |
| + | *'''Text''' is a text string containing characters to extract, | ||
| + | *'''Number_chars''' represents the number of characters to be extracted. | ||
| − | + | RIGHT() displays the last character or characters from a text string, depending on the specified number of characters. | |
| − | + | == Description == | |
| − | |||
| − | |||
| − | + | RIGHT(txt) | |
| − | + | e.g. RIGHT("String",2) displays '''ng''' as a result. | |
| − | + | *RIGHT counts 1 byte per character. RIGHT works with the languages that use 'Single Byte Character Set' (SBCS). | |
| − | + | *'''Text''' can be any string containing characters, numbers, symbols, blank spaces etc. | |
| − | + | *If argument '''Text''' is directly entered in the command, it should be enclosed in double quotes (e.g. "Name"). | |
| + | *Argument '''Number_chars''' indicates the number of characters to be displayed from a text string. '''Number_chars''' should be >0. | ||
| + | *If '''Number_chars''' >'length of text', Calci displays all the text. | ||
| + | *If '''Number_chars''' is omitted, Calci assumes it to be 1. | ||
| − | + | == Examples == | |
| − | |||
| − | |||
| − | + | Consider the following examples as input to RIGHT() function. | |
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
<div id="2SpaceContent" class="zcontent" align="left"> | <div id="2SpaceContent" class="zcontent" align="left"> | ||
{| id="TABLE3" class="SpreadSheet blue" | {| id="TABLE3" class="SpreadSheet blue" | ||
|- class="even" | |- class="even" | ||
| + | | class="sshl_f" |Wel-Come | ||
| class=" " | | | class=" " | | ||
| − | + | | class=" " | | |
| − | | class=" | + | |
| − | |||
| − | |||
|- class="odd" | |- class="odd" | ||
| − | | class=" " | | + | | class="sshl_f" |JOHN SMITH |
| − | | class=" | + | | class=" " | |
| − | | class=" | + | | class=" " | |
| − | + | ||
| − | |||
|- class="even" | |- class="even" | ||
| − | | class=" | + | | class="sshl_f" |123*123 |
| − | | class=" | + | | class=" " | |
| − | | | + | | class=" " | |
| − | | class=" | + | |
| − | |||
| − | |||
|- class="odd" | |- class="odd" | ||
| − | + | | class="sshl_f" | | |
| − | | class=" | + | | class=" " | |
| − | + | | class=" " | | |
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | |||
| − | | | ||
| − | |||
| − | |||
| − | |||
| − | |||
| − | | | ||
| − | | | ||
| − | |||
| − | |||
| − | |||
| − | |||
| − | | | ||
|} | |} | ||
| − | < | + | =RIGHT(A1,5) : Displays last 5 characters in a string from cell A1. Displays '''-Come''' as the output. |
| − | + | =RIGHT(A2,8) : Displays last 8 characters in a string from cell A2. Displays '''HN SMITH''' as the output. <br />Space Character is also counted. | |
| + | =RIGHT(A3,9) : Displays all characters in a string from cell A3. Displays '''123*123''' as the output. | ||
| + | =RIGHTB(A3) : Displays last character in a string from cell A3. Displays '''3''' as the output. | ||
| + | =RIGHT("Good Morning",7) :Displays '''Morning''' as the output. | ||
| + | |||
| + | ==Related Videos== | ||
| + | |||
| + | {{#ev:youtube|cBk20ZZ6A9s|280|center|RIGHT}} | ||
| + | |||
| + | == See Also == | ||
| + | |||
| + | *[[Manuals/calci/RIGHTB | RIGHTB]] | ||
| + | |||
| + | == References == | ||
| + | |||
| + | *[http://en.wikipedia.org/wiki/String_(computer_science) String] | ||
Latest revision as of 12:43, 13 May 2015
RIGHT(Text, Number_chars)
where,
- Text is a text string containing characters to extract,
- Number_chars represents the number of characters to be extracted.
RIGHT() displays the last character or characters from a text string, depending on the specified number of characters.
Description
RIGHT(txt)
e.g. RIGHT("String",2) displays ng as a result.
- RIGHT counts 1 byte per character. RIGHT works with the languages that use 'Single Byte Character Set' (SBCS).
- Text can be any string containing characters, numbers, symbols, blank spaces etc.
- If argument Text is directly entered in the command, it should be enclosed in double quotes (e.g. "Name").
- Argument Number_chars indicates the number of characters to be displayed from a text string. Number_chars should be >0.
- If Number_chars >'length of text', Calci displays all the text.
- If Number_chars is omitted, Calci assumes it to be 1.
Examples
Consider the following examples as input to RIGHT() function.
| Wel-Come | ||
| JOHN SMITH | ||
| 123*123 | ||
=RIGHT(A1,5) : Displays last 5 characters in a string from cell A1. Displays -Come as the output. =RIGHT(A2,8) : Displays last 8 characters in a string from cell A2. Displays HN SMITH as the output.
Space Character is also counted. =RIGHT(A3,9) : Displays all characters in a string from cell A3. Displays 123*123 as the output. =RIGHTB(A3) : Displays last character in a string from cell A3. Displays 3 as the output. =RIGHT("Good Morning",7) :Displays Morning as the output.