Subject Re: Search in string
From Ken Mayer <dbase@nospam.goldenstag.net>
Date Tue, 17 Apr 2018 08:45:06 -0700
Newsgroups dbase.getting-started

On 4/17/2018 8:15 AM, Patrick wrote:
> Dear folks, I know how to count a specific field for a value for example:
>
> count for name=[pinterminal]
>
> But what if the word pinterminal is in different positions in that field? How do I count then? I know the character $ is used, but how?
>
> Many thanks for answering :)
>

count for name $ pinterminal

// note that this is usually case-sensitive, so:

count for lower(name) $ lower( pinterminal )

This is assuming you are using dBL. If you are using SQL:

select count(pinterminal) where pinterminal like "%name%"

(The above is off the top of my head, not having your data, etc.)

Ken

--
*Ken Mayer*
Ken's dBASE Page: http://www.goldenstag.net/dbase
The dUFLP: http://www.goldenstag.net/dbase/index.htm#duflp
dBASE Books: http://www.goldenstag.net/dbase/Books/dBASEBooks.htm
dBASE Tutorial: http://www.goldenstag.net/dbase/Tutorial/00_Preface.htm