Find Field Value

doco

Power User
Local time
Today, 13:56
Joined
Feb 14, 2007
Messages
482
I know I can use
Code:
SELECT
	so.name as table_name
FROM
	sysobjects so inner join syscolumns sc
	on so.id = sc.id
WHERE
	sc.name like 'p%cla%'

To find all tables in a database with a certain field name or name pattern. What I would like to do is write a script that will search all tables for a given field value returning the table name with that field value.

Make Sense?
TIA
 
Thanks a bunch looks like it will do the trick
 

Users who are viewing this thread

Back
Top Bottom