|
|
|
|
||||||
![]() |
|
|
LinkBack | Outils de la discussion |
|
|
#1 |
|
Messages: n/a
Hébergeur: |
I am wondering if anyone has created T-SQL that lists various categories of SQL 2005 objects that quickly lists them. For example, if I wanted to see all the system objects that were related to triggers or if I wanted to see all objects related to constraints. Basically a breakdown of a lot of the useful objects a DBA can use for daily administration (indexes, database mail, SQL jobs, database mirroring etc. etc. etc.).
In essence I'm looking for something to arm me for my day-to-day tasks when its not always easy to remember all of the built-in views / proc's available to us. An example... -- Display all mail related objects select [name], type, type_desc from msdb.sys.objects where type in ( 'P', -- Stored Procedure 'V', -- View 'S', -- System Table 'U', -- User Table 'V' -- View ) and [name] like '%mail%' order by type, [name] Thank-you, Rubens P.S. The reason I thought about this was because I came across sp_text which I had completely forgotten about and can be very useful to see how / what Microsoft is doing with some of their built-in code. |
|
|
|
#2 |
|
Messages: n/a
Hébergeur: |
Rubens
select * from sys.tables select * from sys.views select * from sys.procedures "Rubens" <rubensrose@hotmail.com> wrote in message news:%23Gos61RkIHA.5396@TK2MSFTNGP06.phx.gbl... I am wondering if anyone has created T-SQL that lists various categories of SQL 2005 objects that quickly lists them. For example, if I wanted to see all the system objects that were related to triggers or if I wanted to see all objects related to constraints. Basically a breakdown of a lot of the useful objects a DBA can use for daily administration (indexes, database mail, SQL jobs, database mirroring etc. etc. etc.). In essence I'm looking for something to arm me for my day-to-day tasks when its not always easy to remember all of the built-in views / proc's available to us. An example... -- Display all mail related objects select [name], type, type_desc from msdb.sys.objects where type in ( 'P', -- Stored Procedure 'V', -- View 'S', -- System Table 'U', -- User Table 'V' -- View ) and [name] like '%mail%' order by type, [name] Thank-you, Rubens P.S. The reason I thought about this was because I came across sp_text which I had completely forgotten about and can be very useful to see how / what Microsoft is doing with some of their built-in code. |
|
|
|
#3 |
|
Messages: n/a
Hébergeur: |
Thank-you Uri. This isn't exactly what I was looking for but it will be a to search these views as well.
Rubens "Uri Dimant" <urid@iscar.co.il> wrote in message news:eYasnikkIHA.980@TK2MSFTNGP06.phx.gbl... Rubens select * from sys.tables select * from sys.views select * from sys.procedures "Rubens" <rubensrose@hotmail.com> wrote in message news:%23Gos61RkIHA.5396@TK2MSFTNGP06.phx.gbl... I am wondering if anyone has created T-SQL that lists various categories of SQL 2005 objects that quickly lists them. For example, if I wanted to see all the system objects that were related to triggers or if I wanted to see all objects related to constraints. Basically a breakdown of a lot of the useful objects a DBA can use for daily administration (indexes, database mail, SQL jobs, database mirroring etc. etc. etc.). In essence I'm looking for something to arm me for my day-to-day tasks when its not always easy to remember all of the built-in views / proc's available to us. An example... -- Display all mail related objects select [name], type, type_desc from msdb.sys.objects where type in ( 'P', -- Stored Procedure 'V', -- View 'S', -- System Table 'U', -- User Table 'V' -- View ) and [name] like '%mail%' order by type, [name] Thank-you, Rubens P.S. The reason I thought about this was because I came across sp_text which I had completely forgotten about and can be very useful to see how / what Microsoft is doing with some of their built-in code. |
|
![]() |
| Outils de la discussion | |
|
|