>Jess,
>I cannot think of an easy solution. The only thing that comes to mind is to convert cDesc into an array and then build the WHERE clause using the syntax Sergey has suggested for each word. In any case, the query won't be optimized with these kind of operators.
>Since you mentioned SQL Server, you may consider Full-Text Search, although I have no personal experience with this feature. If you were looking for a pure VFP solution, then phdBase would be an alternative.
Actually, there's a completely trivial solution; simply parse the string cDesc and generate a unique WHERE clause at runtime. Using a regular expression parser such as VBScript.RegExp, you could create a regular expression which, when applied, would return a collection of tokens which could then be used to construct LIKE expressions immediately prior to invoking the SELECT statement; it might be worthwhile implementing it as an SP on each platform and taking advantage of platform-specific behaviors implementing the SELECT on each discrete platform.
Honestly, it's a broadly boring problem; the table could easily be restructured to parse the description field into a supernormal set of attributes describing the record, and the query is then posed against the attribute set for each record. At that point, the query becomes optimizable...