1

Topic: Whether to learn there is a record in tables of stored procedure

There is some dial-up of stored procedures in which a lot of code. Whether it is possible to understand (profiler th, extended events or somehow differently) without analyzing the code - whether there is in this a procedure record in basis tables?
In basis many people simultaneously work, therefore is simple on change of the size of tables not to trace.

2

Re: Whether to learn there is a record in tables of stored procedure

QC;
Record in tables is carried out by operators UPDATE, INSERT, MERGE
Yours TO

3

Re: Whether to learn there is a record in tables of stored procedure

iiyama wrote:

QC;
Record in tables is carried out by operators UPDATE, INSERT, MERGE
Yours TO

Or enclosed , in which..... (Recursion) smile

4

Re: Whether to learn there is a record in tables of stored procedure

LSV wrote:

it is passed...
Or enclosed , in which..... (Recursion) smile

And still there are triggers, CLR th procedures and functions, loopback servers and other dynamic SQL

5

Re: Whether to learn there is a record in tables of stored procedure

iiyama wrote:

QC;
Record in tables is carried out by operators UPDATE, INSERT, MERGE
Yours TO

Well and still rollback unsuccessful DELETE, in any sense it too record in basis tables.

6

Re: Whether to learn there is a record in tables of stored procedure

QC;
Cut SQL SERVER AUDIT and long think, what for generally it was required to you smile

7

Re: Whether to learn there is a record in tables of stored procedure

In a primitive variant as that so;
Accordingly if it is necessary for you to catch in addition changes in tables filters on update, delete, merge

CREATE EVENT SESSION [catch_proclist_insert] ON SERVER
ADD EVENT sqlserver.sp_statement_completed (SET collect_object_name = (1), collect_statement = (1)
ACTION (sqlserver.sql_text)
WHERE (
[sqlserver]. [like_i_sql_unicode_string] ([sqlserver]. [sql_text], N ' %INSERT % ')
AND
[package0]. [greater_than_uint64] ([row_count], (0))
AND
[sqlserver]. [equal_i_sql_unicode_string] ([sqlserver]. [database_name], N'DBNAME ')
AND
[sqlserver]. [like_i_sql_unicode_string] ([statement], N'INSERT % ')
AND
[package0]. [greater_than_uint64] ([writes], (0))
AND
([object_name] =N'procedure1 ' OR [object_name] =N'procedure2 ' OR [object_name] =N'procedure3 ')
)
)
ADD TARGET package0.ring_buffer (SET max_memory = (32768))
WITH (MAX_MEMORY=4096 KB,EVENT_RETENTION_MODE=ALLOW_SINGLE_EVENT_LOSS,MAX_DISPATCH_LATENCY=30 SECONDS, MAX_EVENT_SIZE=0 KB,MEMORY_PARTITION_MODE=NONE,TRACK_CAUSALITY=OFF,STARTUP_STATE=OFF)
GO

Or create audit on insert, update, delete truth with it is necessary tinkers for it is hung up on the given events on separate essence, it is necessary to write the code extensive if it is necessary to catch change events on all tables of a DB