Get the App
SLTechnology News&Howtos  ›  Database  › 

How to batch view the tables and fields of characters in Sql

Shulou Source: shulou.com Published: 2022-05-31 19:25:34 10月03日 Update

This article introduces how to batch view the tables and fields of characters in Sql, the content is very detailed, interested friends can refer to it, I hope it can be helpful to you.

The code is as follows: declare @ str varchar (100) set @ str='8f8el3l' declare @ s varchar (8000) declare tb cursor local for select s='if exists (select 1 from ['+ b.nameplate'] where ['+ a.nameplate'] like'%'+ @ str+'%'') print''is the table and field: ['+ b.nameplate']. ['+ a.namehorse'] 'from syscolumns a join sysobjects b on a.id=b.id where b.xtyperoomU' and a.status > = 0 And a.xusertype in (175239231167) 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

This is the end of the table and field sharing on how to batch view the characters in Sql. I hope the above content can be of some help and learn more knowledge. If you think the article is good, you can share it for more people to see.

Tags: Fields location characters content more help good code interests guys buddies articles knowledge articles references Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno NVidia MySQL macOS Linux Microsoft