T-SQL: Script to Find the Names of Stored Procedures that Use Dynamic SQL ( Method 2 )

First method was using dynamic management function – sys.dm_sql_referenced_entities . Fun with system functions continues … Here is the second method : Using dynamic management function – sys.dm_exec_describe_first_result_set SELECT  SP_Name,error_message,error_type_desc FROM (SELECT schema_name(schema_id)+’.’+name SP_Name FROM sys.procedures ) tmpCROSS APPLY sys.dm_exec_describe_first_result_set (SP_Name, NULL, 0)WHERE error_type = 4 See Also : http://www.codefloor.com/?p=79 T-SQL Script to find Stored…

Details

SQL Server – Dynamic SQL – SQL Injection – EXEC [ QUOTENAME() , REPLACE() , EXECUTE AS ] – Sp_executesql – [ RECOMPILE ]

Recently I had mess up with dynamic SQL , So whats next !!! , I started to explore on this topic and post it here , when I googled to gather some information , but what I found was , this topic has been already drilled to the core , carved and with the sculpture…

Details