close

I have a workbook that has two sheets. The first sheet is called
'Objects' and the second sheet is called 'RawData'. The 'Objects'
sheet has values down the A column. There are about 4,000 rows. The
values are just simple strings.

In the 'RawData' sheet, I just have output of code from an entire
application. So basically, it is a bunch of text.

How can I find out if the string in A1 (then A2, A3, A4....) exists
anywhere within the 'RawData' sheet? If it does exists then I just
want to put a '***' (or any type of flag) on B1 (or B2, B3, B4...) in
the 'Objects' sheet, and if the string isn't in the 'RawData' sheet,
then leave cell B1 blank.

Thank You,
Jon WetzelYou can try this Jon

=IF(COUNTIF(A1,RawData!A:IV)gt;0,quot;existquot;,quot;not existquot;)

--
Regards Ron de Bruin
www.rondebruin.nlquot;Jonquot; gt; wrote in message ups.com...
gt;I have a workbook that has two sheets. The first sheet is called
gt; 'Objects' and the second sheet is called 'RawData'. The 'Objects'
gt; sheet has values down the A column. There are about 4,000 rows. The
gt; values are just simple strings.
gt;
gt; In the 'RawData' sheet, I just have output of code from an entire
gt; application. So basically, it is a bunch of text.
gt;
gt; How can I find out if the string in A1 (then A2, A3, A4....) exists
gt; anywhere within the 'RawData' sheet? If it does exists then I just
gt; want to put a '***' (or any type of flag) on B1 (or B2, B3, B4...) in
gt; the 'Objects' sheet, and if the string isn't in the 'RawData' sheet,
gt; then leave cell B1 blank.
gt;
gt; Thank You,
gt; Jon Wetzel
gt;
Sorry for the wrong formula

=IF(COUNTIF(RawData!A:A,A1)gt;0,quot;existquot;,quot;not existquot;)

--
Regards Ron de Bruin
www.rondebruin.nlquot;Ron de Bruinquot; gt; wrote in message ...
gt; You can try this Jon
gt;
gt; =IF(COUNTIF(A1,RawData!A:IV)gt;0,quot;existquot;,quot;not existquot;)
gt;
gt; --
gt; Regards Ron de Bruin
gt; www.rondebruin.nl
gt;
gt;
gt; quot;Jonquot; gt; wrote in message ups.com...
gt;gt;I have a workbook that has two sheets. The first sheet is called
gt;gt; 'Objects' and the second sheet is called 'RawData'. The 'Objects'
gt;gt; sheet has values down the A column. There are about 4,000 rows. The
gt;gt; values are just simple strings.
gt;gt;
gt;gt; In the 'RawData' sheet, I just have output of code from an entire
gt;gt; application. So basically, it is a bunch of text.
gt;gt;
gt;gt; How can I find out if the string in A1 (then A2, A3, A4....) exists
gt;gt; anywhere within the 'RawData' sheet? If it does exists then I just
gt;gt; want to put a '***' (or any type of flag) on B1 (or B2, B3, B4...) in
gt;gt; the 'Objects' sheet, and if the string isn't in the 'RawData' sheet,
gt;gt; then leave cell B1 blank.
gt;gt;
gt;gt; Thank You,
gt;gt; Jon Wetzel
gt;gt;
gt;
gt;
That works if the string I am searching is in the other sheet in a cell
by itself. However, if the string I am looking for is going to be in
the middle of other text, then it won't work. 99% of the time the
string will be mixed in with other text.

For example: The objects sheet contains a list of table names. And
the raw data is the export of Powerbuilder Powerscript code. I want to
see which tables are referenced by embedded SQL in the code. So, if I
am searching for the EMPLOYEE table, it would exist in a cell that
looks like this ---gt; quot;Select name, address, zip from EMPLOYEE where
name = 'Jon'quot; Does this make better sense?

I should have been more specific in my first post.

Thanks for your help so far.Hi

You can use this Functions

if(iserror(vlookup(lookup vlaue, lookup in raw data, Column No.,
false)),,quot;****quot;)
This function is write Zero Where there is no match and put *** where
there is matching value is available.

Regards
Krupesh=IF(COUNTIF(RawData!A:A,quot;*quot;amp;A1amp;quot;*quot;)gt;0,quot;existquot;,quot;not existquot;)

--
Regards,

Peo Sjoblom

Portland, Oregon

quot;Jonquot; gt; wrote in message ups.com...
gt; That works if the string I am searching is in the other sheet in a cell
gt; by itself. However, if the string I am looking for is going to be in
gt; the middle of other text, then it won't work. 99% of the time the
gt; string will be mixed in with other text.
gt;
gt; For example: The objects sheet contains a list of table names. And
gt; the raw data is the export of Powerbuilder Powerscript code. I want to
gt; see which tables are referenced by embedded SQL in the code. So, if I
gt; am searching for the EMPLOYEE table, it would exist in a cell that
gt; looks like this ---gt; quot;Select name, address, zip from EMPLOYEE where
gt; name = 'Jon'quot; Does this make better sense?
gt;
gt; I should have been more specific in my first post.
gt;
gt; Thanks for your help so far.
gt;Thank you, Peo.=IF(COUNTIF(RawData!A:A,quot;*quot;amp;A1amp;quot;*quot;)gt;0,quot;existquot;,quot;not existquot;)

WORKED BEAUTIFULLY.Hi Jon

See also
www.j-walk.com/ss/excel/tips/tip52.htm

--
Regards Ron de Bruin
www.rondebruin.nlquot;Jonquot; gt; wrote in message oups.com...
gt; Thank you, Peo.
gt;
gt;
gt; =IF(COUNTIF(RawData!A:A,quot;*quot;amp;A1amp;quot;*quot;)gt;0,quot;existquot;,quot;not existquot;)
gt;
gt; WORKED BEAUTIFULLY.
gt;

全站熱搜
創作者介紹
創作者 software 的頭像
software

software

software 發表在 痞客邦 留言(0) 人氣()