If this script should run on MS SQL Server, you have to fix it first!!!!
Umm...this script ran fine in 2005. Tested in master, AdventureWorks, and a couple other databases. What was the problem with it? It returns the table name, column name, and column type which should be enough.
________________________________________________________________"In theory, theory and practice are the same. In practice, they are not."
- Albert Einstein