Difference between revisions of "Manuals/calci/SEARCH"

From ZCubes Wiki
Jump to navigation Jump to search
(Created page with "<div id="6SpaceContent" class="zcontent" align="left"> <font color="#484848"><font face="Arial, sans-serif"><font size="2">'''SEARCH'''</font></font></font><font color="#48...")
 
Line 1: Line 1:
<div id="6SpaceContent" class="zcontent" align="left">
+
=SEARCH(ftext, otext, snum)=
  
<font color="#484848"><font face="Arial, sans-serif"><font size="2">'''SEARCH'''</font></font></font><font color="#484848"><font face="Arial, sans-serif"><font size="2">(</font></font></font><font color="#484848"><font face="Arial, sans-serif"><font size="2">'''ftxt'''</font></font></font><font color="#484848"><font face="Arial, sans-serif"><font size="2">,</font></font></font><font color="#484848"><font face="Arial, sans-serif"><font size="2">'''wtxt'''</font></font></font><font color="#484848"><font face="Arial, sans-serif"><font size="2">,snum)</font></font></font>
+
where
 +
*<math>ftext</math> is the text to search in original string,
 +
*<math>otext</math> is the original string from which mentioned text is to be searched, and
 +
*<math>snum</math> is an optional argument that specifies the character position to start the search.
  
<font color="#484848"><font face="Arial, sans-serif"><font size="2">where ftxt   is the text that want to find and wxt is the text ithat want to search for ftxt and</font></font></font>
+
SEARCH() identifies the occurrence of specified text string from the original string and returns the starting position of the matched string.
  
<font color="#484848"><font face="Arial, sans-serif"><font size="2">'''snum'''</font></font></font><font color="#484848"><font face="Arial, sans-serif"><font size="2">   is the character number in wtxtt .</font></font></font>
+
== Description ==
  
</div>
+
SEARCH(ftext, otext, snum)
----
 
<div id="1SpaceContent" class="zcontent" align="left"><font size="2" color="#484848" face="Arial">SEARCH identify one text string within a second text string, and brings the number of the starting position of the first text string from the first character of the second text string. </font>
 
  
<font color="#ff0000"><font face="Arial, sans-serif"><font size="2">Note</font></font></font><font color="#484848"><font face="Arial, sans-serif"><font size="2">:SEARCH use the single-byte character set (SBCS</font></font></font>
+
For Example,
  
</div>
+
SEARCH("COME", "WELCOME",1) returns ''4''
----
 
<div id="12SpaceContent" class="zcontent" align="left"><div class="ZEditBox" align="left">
 
  
SEARCH
+
*SEARCH function can be used to find text within a text. SEARCH counts 1 byte per characters. MID works with the languages that use 'Single Byte Character Set' (SBCS).
 +
*<math>otext</math> can be any string containing characters, numbers, symbols, blank spaces etc.
 +
*<math>ftext</math> and <math>otext</math> when directly entered in the command, should be enclosed in double quotes (e.g. "Name").
 +
*Argument <math>snum</math> is optional. If omitted, Calci assumes to be 1.
 +
*<math>snum</math> should be an integer &gt; 0, else Calci displays #NULL error message.
 +
*If <math>snum</math> &gt; 'length of text', Calci displays #N/A error message.
 +
*If string specified in <math>otext</math> is not a part of the reference string <math>txt</math>, Calci returns #N/A error string.
  
</div></div>
+
== Examples ==
----
 
<div id="8SpaceContent" class="zcontent" align="left">
 
  
<font color="#484848"><font face="Arial, sans-serif"><font size="2">Let’s see an example in (Column1 Row 1)</font></font></font>
+
<div id="6SpaceContent" class="zcontent" align="left">
 
 
<font size="2" color="#666666" face="Arial">C1R1 = Beautiful</font>
 
 
 
<font color="#666666"><font face="Arial, sans-serif"><font size="2">
 
 
 
<font color="#666666"><font face="Arial, sans-serif"><font size="2">I.e.= SE</font></font></font>ARCH(“f”,C1R1,3) is 7
 
 
 
</font></font></font></div>
 
----
 
<div id="10SpaceContent" class="zcontent" align="left"><div class="ZEditBox" align="justify">Syntax </div><div class="ZEditBox"><center></center></div></div>
 
----
 
<div id="3SpaceContent" class="zcontent" align="left"><div class="ZEditBox" align="justify">Examples </div></div>
 
----
 
<div id="11SpaceContent" class="zcontent" align="left"><div class="ZEditBox" align="justify">Description </div></div>
 
----
 
<div id="2SpaceContent" class="zcontent" align="left">
 
  
 
{| id="TABLE3" class="SpreadSheet blue"
 
{| id="TABLE3" class="SpreadSheet blue"
 
|- class="even"
 
|- class="even"
| class=" " |
+
| class="ssh1_f" |SEARCH
| Column1
+
| class="  " |
| class="  " | Column2
+
| class="  " |
| Column3
+
 
| Column4
 
 
|- class="odd"
 
|- class="odd"
| class=" " | Row1
+
| class="ssh1_f" |Happy New Year!!!
| class=" " | Beautiful
+
| class=" " |
| class="sshl_f" | 7
+
| class=" " |
|
+
 
| class="                                                            sshl_f  " |
 
 
|- class="even"
 
|- class="even"
| class=" " | Row2
+
| class="ssh1_f" |
| class="sshl_f    " |
+
| class=" " |
<div id="2Space_Copy" title="Click and Drag over to AutoFill other cells."></div>
 
| class=" SelectTD SelectTD" |
 
<div id="2Space_Handle" title="Click and Drag to resize CALCI Column/Row/Cell. It is EZ!"></div><div id="2Space_Copy" title="Click and Drag over to AutoFill other cells."></div>
 
|
 
|
 
|- class="odd"
 
| Row3
 
| class="                                      sshl_f        " |
 
|
 
|
 
|
 
|- class="even"
 
| Row4
 
|
 
|
 
|
 
 
| class="  " |
 
| class="  " |
|- class="odd"
+
 
| class=" " | Row5
 
|
 
|
 
|
 
|
 
|- class="even"
 
| Row6
 
|
 
|
 
|
 
|
 
 
|}
 
|}
  
<div align="left">[[Image:calci1.gif]]</div></div>
+
=SEARCH("A", A1) : Returns '''3''' as output.
----
+
=SEARCH("New", A2) : Returns '''7''' as output. Space character is also counted.
 +
=SEARCH("Year",A2,6) : Search is started from 6th position. Returns '''11''' as output. <br />Space character is also counted.
 +
 
 +
== See Also ==
 +
 
 +
*[[Manuals/calci/REPLACE | REPLACE]]
 +
*[[Manuals/calci/REPT | REPT]]
 +
 
 +
==References==
 +
 
 +
*[http://en.wikipedia.org/wiki/Autocorrection Find and Replace]

Revision as of 06:29, 11 February 2014

SEARCH(ftext, otext, snum)

where

  • Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle ftext} is the text to search in original string,
  • Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle otext} is the original string from which mentioned text is to be searched, and
  • Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle snum} is an optional argument that specifies the character position to start the search.

SEARCH() identifies the occurrence of specified text string from the original string and returns the starting position of the matched string.

Description

SEARCH(ftext, otext, snum)

For Example,

SEARCH("COME", "WELCOME",1) returns 4

  • SEARCH function can be used to find text within a text. SEARCH counts 1 byte per characters. MID works with the languages that use 'Single Byte Character Set' (SBCS).
  • Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle otext} can be any string containing characters, numbers, symbols, blank spaces etc.
  • Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle ftext} and Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle otext} when directly entered in the command, should be enclosed in double quotes (e.g. "Name").
  • Argument Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle snum} is optional. If omitted, Calci assumes to be 1.
  • Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle snum} should be an integer > 0, else Calci displays #NULL error message.
  • If Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle snum} > 'length of text', Calci displays #N/A error message.
  • If string specified in Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle otext} is not a part of the reference string Failed to parse (MathML with SVG or PNG fallback (recommended for modern browsers and accessibility tools): Invalid response ("Math extension cannot connect to Restbase.") from server "https://wikimedia.org/api/rest_v1/":): {\displaystyle txt} , Calci returns #N/A error string.

Examples

SEARCH
Happy New Year!!!
=SEARCH("A", A1) : Returns 3 as output.
=SEARCH("New", A2) : Returns 7 as output. Space character is also counted.
=SEARCH("Year",A2,6) : Search is started from 6th position. Returns 11 as output. 
Space character is also counted.

See Also

References