DatabaseProcApplicationCreatedLinks
sybsystemprocssp_tran_dumpable_status  14 déc. 14Defects Propagation Dependencies

1     
2     
3     /*
4     ** This stored procedure translates to text the bitmap
5     ** returned by the built-in tran_dumpable_status().
6     **
7     ** Parameters:
8     **      @dbname         - DB name to query or NULL for current
9     **
10    */
11    create or replace procedure sp_tran_dumpable_status @dbname sysname = NULL
12    as
13        begin
14            declare @status int
15    
16            if (@dbname is null)
17                select @dbname = db_name()
18    
19            select @status = tran_dumpable_status(@dbname)
20    
21            select bit = power(2, a.number), description = a.name
22            from master.dbo.spt_values a
23            where a.type = 'DX'
24                and @status & power(2, a.number) != 0
25    
26            return (0)
27        end
28    
29    


exec sp_procxmode 'sp_tran_dumpable_status', 'AnyMode'
go

Grant Execute on sp_tran_dumpable_status to public
go
RESULT SETS
sp_tran_dumpable_status_rset_001

DEFECTS
 TNOU 4 Table with no unique index master..spt_values master..spt_values
 MGTP 3 Grant to public master..spt_values  
 MGTP 3 Grant to public sybsystemprocs..sp_tran_dumpable_status  
 MUCO 3 Useless Code Useless Begin-End Pair 13
 MUCO 3 Useless Code Useless Brackets 16
 MUCO 3 Useless Code Useless Brackets 26
 MRST 2 Result Set Marker 21
 MTR1 2 Metrics: Comments Ratio Comments: 25% 11
 MTR2 2 Metrics: Cyclomatic Complexity Cyclo: 3 = 2dec - 1exi + 2 11
 MTR3 2 Metrics: Query Complexity Complexity: 11 11

DEPENDENCIES
PROCS AND TABLES USED
reads table master..spt_values (1)  
writes table sybsystemprocs..sp_tran_dumpable_status_rset_001