블로그 이미지
bedbmsguru

Notice

Recent Post

Recent Comment

Recent Trackback

Archive

calendar

1 2 3 4 5 6
7 8 9 10 11 12 13
14 15 16 17 18 19 20
21 22 23 24 25 26 27
28 29 30
  • total
  • today
  • yesterday
2018. 10. 27. 22:47 SQL SERVER

select                       distinct
                                                 ObjectType                            = o .type_desc
                                 ,                ObjectName                           = o .name
                                 ,                CodeSequence     = c_display. colid
                                 ,                Code                                        = c_display .[text]
from                         sys.objects o
inner join                 sys.syscomments c_search
                                                 on c_search .id = o .[object_id]
inner join                 sys.syscomments c_display
                                                 on c_display .id = o .[object_id]
where                      o.type_desc not in ( 'INTERNAL_TABLE','SERVICE_QUEUE' ,'SYSTEM_TABLE')
and                                          c_search.[text] like '%temp%'
order by  1, 2 , 3


posted by bedbmsguru