This script will return how many time one string occurs within another. It will only work on SQL 2K as it is a UDF, but it could be converted to a stored proc with a output variable for SQL 7.0.
2004-10-01 (first published: 2002-06-20)
15,386 reads