Skip to content

Commit

Permalink
2.5.7460.35921 - Fixed an issue where table utilisation was not being…
Browse files Browse the repository at this point in the history
… collected for databases other than SQLWATCH. As all tables are being processed now, the execution time for [dbo].[usp_sqlwatch_logger_disk_utilisation_table] may increase considerably. Please test it in your enviroment first.
  • Loading branch information
marcingminski committed Jun 4, 2020
1 parent d962f76 commit aaee579
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
4 changes: 2 additions & 2 deletions SQLWATCHDB/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,5 @@
// Build Number
// Revision
//
[assembly: AssemblyVersion("2.4.*")]
[assembly: AssemblyFileVersion("2.4.0.0")]
[assembly: AssemblyVersion("2.5.*")]
[assembly: AssemblyFileVersion("2.5.0.0")]
Binary file modified SQLWATCHDB/Scripts/Pre-Deployment/SetDacVersion.sql
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -57,11 +57,11 @@ select
/* only take table compression into account and not index compression.
we have index analysis elsewhere */
[data_compression] = max(case when i.index_id = 0 then p.[data_compression] else 0 end)
from sys.tables t
inner join sys.indexes i on t.object_id = i.object_id
inner join sys.partitions p on i.object_id = p.object_id AND i.index_id = p.index_id
inner join sys.allocation_units a on p.partition_id = a.container_id
inner join sys.schemas s on t.schema_id = s.schema_id
from [?].sys.tables t
inner join [?].sys.indexes i on t.object_id = i.object_id
inner join [?].sys.partitions p on i.object_id = p.object_id AND i.index_id = p.index_id
inner join [?].sys.allocation_units a on p.partition_id = a.container_id
inner join [?].sys.schemas s on t.schema_id = s.schema_id
inner join sys.databases sdb on sdb.name = ''?''
group by s.name, t.name, sdb.name, sdb.create_date;
Expand Down

0 comments on commit aaee579

Please sign in to comment.