 




<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: CHECK vs SCAN</title>
	<atom:link href="http://itknowledgeexchange.techtarget.com/itanswers/check-vs-scan/feed/" rel="self" type="application/rss+xml" />
	<link>http://itknowledgeexchange.techtarget.com/itanswers/check-vs-scan/</link>
	<description></description>
	<lastBuildDate>Fri, 24 May 2013 10:59:22 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	
	<item>
		<title>By: philpl1jb</title>
		<link>http://itknowledgeexchange.techtarget.com/itanswers/check-vs-scan/#comment-57021</link>
		<dc:creator>philpl1jb</dc:creator>
		<pubDate>Fri, 10 Oct 2008 14:11:24 +0000</pubDate>
		<guid isPermaLink="false">#comment-57021</guid>
		<description><![CDATA[Check might be used to test a text string to determine if it&#039;s a valid UPC number - (only digits)

ValidSTR = &#039;1234567890&#039;
ValidSTR   Check  UPCSTR    BadPos
if BadPos &gt; 0
Exsr BadUPCSTR
Endif

Here the string UPCSTR is tested for any value other than the 10 digits
If UPCSTR = &#039;92AB569ZZ999&#039;
then BadPos would contain the value 3 - the first position containing the character &#039;A&#039; 
because that character wasn&#039;t in the ValidSTR &#039;

Newer function that does the same thing
BadPos = %CHECK( ValidSTR : UPCSTR)
----------------------------------------------------------------------
Scan would be used in a text search situation like partial name

SearchStr = &#039;BOB&#039;

SearchStr  SCAN  FullNameStr
If %found
 Exsr AddRecSFL
Endif


Found values would be &#039;BOB BLAKE&#039;, &#039;JIM ROBOBD&#039;, &#039;SUE BOBBY BOOP&#039;
Not Found values would be &#039;Bob Blake&#039;, &#039;PHIL GORILLA&#039;, &#039;MAX SMITH&#039;

Alternative format

PosFnd = %SCAN( SearchStr : FullNameStr)
If PosFnd &gt; 0
...

or 

If %SCAN( SearchStr : FullNameStr) &gt; 0]]></description>
		<content:encoded><![CDATA[<p>Check might be used to test a text string to determine if it&#8217;s a valid UPC number &#8211; (only digits)</p>
<p>ValidSTR = &#8217;1234567890&#8242;<br />
ValidSTR   Check  UPCSTR    BadPos<br />
if BadPos &gt; 0<br />
Exsr BadUPCSTR<br />
Endif</p>
<p>Here the string UPCSTR is tested for any value other than the 10 digits<br />
If UPCSTR = &#8217;92AB569ZZ999&#8242;<br />
then BadPos would contain the value 3 &#8211; the first position containing the character &#8216;A&#8217;<br />
because that character wasn&#8217;t in the ValidSTR &#8216;</p>
<p>Newer function that does the same thing<br />
BadPos = %CHECK( ValidSTR : UPCSTR)<br />
&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;-<br />
Scan would be used in a text search situation like partial name</p>
<p>SearchStr = &#8216;BOB&#8217;</p>
<p>SearchStr  SCAN  FullNameStr<br />
If %found<br />
 Exsr AddRecSFL<br />
Endif</p>
<p>Found values would be &#8216;BOB BLAKE&#8217;, &#8216;JIM ROBOBD&#8217;, &#8216;SUE BOBBY BOOP&#8217;<br />
Not Found values would be &#8216;Bob Blake&#8217;, &#8216;PHIL GORILLA&#8217;, &#8216;MAX SMITH&#8217;</p>
<p>Alternative format</p>
<p>PosFnd = %SCAN( SearchStr : FullNameStr)<br />
If PosFnd &gt; 0<br />
&#8230;</p>
<p>or </p>
<p>If %SCAN( SearchStr : FullNameStr) &gt; 0</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: tram</title>
		<link>http://itknowledgeexchange.techtarget.com/itanswers/check-vs-scan/#comment-57015</link>
		<dc:creator>tram</dc:creator>
		<pubDate>Fri, 10 Oct 2008 07:00:29 +0000</pubDate>
		<guid isPermaLink="false">#comment-57015</guid>
		<description><![CDATA[Hi Philip or anybody
thanks for your answer. But still i am confused by the example you have given and Factor1 and Factor2 and result. Can you please elaborate and excplain it clearly with a better example...

regards
Ram]]></description>
		<content:encoded><![CDATA[<p>Hi Philip or anybody<br />
thanks for your answer. But still i am confused by the example you have given and Factor1 and Factor2 and result. Can you please elaborate and excplain it clearly with a better example&#8230;</p>
<p>regards<br />
Ram</p>
]]></content:encoded>
	</item>
</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Page Caching using memcached
Database Caching 3/10 queries in 0.042 seconds using memcached
Object Caching 281/287 objects using memcached

Served from: itknowledgeexchange.techtarget.com @ 2013-05-24 12:03:29 -->