代码如下:USE [数据库名称]; –1.定义需要查找的关键字。在搜索中,使用模糊搜索:LIKE ‘%@key_find%’ DECLARE @key_find NVARCHAR(MAX) = ‘123’;–假设是找字符串”123′′ –2.用游标Cursor_Table,遍历所有表 DECLARE Cursor_Table CURSOR FOR SELECT name from sysobjects WHERE xtype = ‘u’ AND name <> ‘dtproperties’; OPEN Cursor_Table; DECLARE @tableName NVARCHA