On 1/17/11 3:26 PM, Alan Campin wrote:
Never mind. I figured it out.

InSearchString = '%' + InSearchString + '%';

Select Count(*)
From QTEMP/OUT132
Where OUT132 Like(:InSearchString);

where InSearchString is defined as 50a Varying works.

FWiW a 49-byte search-string will /break/ using that method. Using the SQL CONCAT instead [as suggested by others] to add the percent sign as both a prefix and a suffix may be better than either documenting a 48-byte limitation or adding a new\longer string host variable to accommodate the two additional bytes.

Regards, Chuck

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2026 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.