2 Replies Latest reply on Apr 22, 2010 1:35 AM by raybaudi

    Finding text in a field



      Finding text in a field


      I would like to have a field that notifies if another field contains a certain word. For example I can use:


      "Sample Field"  calculation is If(Field A="test",yes)


      But if Field A a contains, "test today" the Sample Field will be blank. How do I get it to still show "yes"?



        • 1. Re: Finding text in a field

          One way to do this is with PatternCount ( Text ; SearchString )

          Try : 

          If ( patterncount (Field A ; "test" ) >= 1 ; "yes" ; "no" )


          PatternCount gives you the ability to search a given text field for a specific string.  The return is how many times the string appears.  So if it is >= 1 then your string appears at least once.  So if you are looking for "test" and it appears in Field A, Patterncount will give >=1 and the test field will show "yes" otherwise it will show "no."


          Hope this helps



          • 2. Re: Finding text in a field

            If( PatternCount ( Field A ; "test" ) ; "Yes" )