Sql 批量查看字符所在的表及字段
时间:2024-01-15 02:53:36
declare @str varchar(100)
set @str='8f8el3l'
declare @s varchar(8000)
declare tb cursor local for
select s='if exists(select 1 from ['+b.name+'] where ['+a.name+'] like ''%'+@str+'%'')
print ''所在的表及字段: ['+b.name+'].['+a.name+']'''
from syscolumns a join sysobjects b on a.id=b.id
where b.xtype='U' and a.status>=0
and a.xusertype in(175,239,231,167)
open tb
fetch next from tb into @s
while @@fetch_status=0
begin
exec(@s)
fetch next from tb into @s
end
close tb
deallocate tb
标签:Sql,批量查看
![](/images/zang.png)
![](/images/jiucuo.png)
猜你喜欢
Python实现直播推流效果
2023-10-06 12:43:29
![](https://img.aspxhome.com/file/2023/5/124355_0s.gif)
ASP连接Access数据库和SQL server数据库的方法
2007-08-22 13:16:00
图解Python中浅拷贝copy()和深拷贝deepcopy()的区别
2021-12-09 21:09:39
![](https://img.aspxhome.com/file/2023/0/84970_0s.png)
python numpy中对ndarry按照index增删改查
2022-01-20 22:32:25
pythotn条件分支与循环详解
2021-12-02 12:20:08
![](https://img.aspxhome.com/file/2023/8/126918_0s.png)
如何在Python项目中引入日志
2023-01-25 15:10:53
![](https://img.aspxhome.com/file/2023/7/67757_0s.png)
Python3实现捕获Ctrl+C终止信号
2021-10-17 14:03:55
Python中的字典遍历备忘
2021-12-08 05:59:37
Mac Homebrew安装的MySQL无法远程登录的解决
2024-01-14 12:12:56
Sun拟10亿美元收购MySQL
2008-01-17 11:56:00
Python实现爬取亚马逊数据并打印出Excel文件操作示例
2021-09-10 05:10:36
![](https://img.aspxhome.com/file/2023/3/105203_0s.png)
跟老齐学Python之集合的关系
2023-02-04 22:32:27
![](https://img.aspxhome.com/file/2023/8/77028_0s.png)
Matplotlib中%matplotlib inline如何使用
2021-11-22 15:17:41
![](https://img.aspxhome.com/file/2023/4/89314_0s.png)
详解python metaclass(元类)
2023-08-21 10:09:04
SQL Server2005打开数据表中的XML内容时报错的解决办法
2024-01-18 01:32:12
![](https://img.aspxhome.com/file/2023/0/106200_0s.jpg)
Python源码学习之PyType_Type和PyBaseObject_Type详解
2023-08-03 15:50:05
![](https://img.aspxhome.com/file/2023/3/61733_0s.png)
MYSQL 数据库同步
2008-11-24 12:39:00
JavaScript中匿名函数用法实例
2024-04-19 09:51:19
Go语言中内存管理逃逸分析详解
2024-05-08 10:13:48
浅谈JavaScript函数节流
2024-05-03 15:59:31
![](https://img.aspxhome.com/file/2023/7/129077_0s.png)