Open hvoges opened 1 year ago
Thanks. I recall this issue but thought it was fixed. I'll look into it.
I used the Json-Files from the Github-Repo here: https://github.com/marcingminski/sqlwatch/tree/main/SqlWatch.Dashboard/Grafana Is there a more current version?
I just checked this in my test env, and the count is correct. Can you check if this view [dbo].[vw_sqlwatch_report_dim_database]
returns the right databases, or let me see the results in CSV please?
And could you let me see results from this:
select *
from dbo.sqlwatch_meta_server s
outer apply (
select *
from [dbo].[vw_sqlwatch_report_dim_database] db
where db.sql_instance = s.sql_instance
and db.database_name = DB_NAME()
) dbs
Attached you find the results of the SQLwatch_meta_Server query. sqlwatch_meta.csv
Describe the bug If Grafana-Dashboard uses a Central Repository as the Data-Source, the Instance-Overview always shows only the database-Number of the last Instance in the List.
To Reproduce Open the Grafana-Dashboard for a Central Repository and open the SQL Instance Overview. All-Databases shows the same number of databases for each instance.
Expected behavior Database Count and Growth should be shown according to the filter settings.
Screenshots![image](https://user-images.githubusercontent.com/6452224/194310371-25660ad0-1861-4387-9cf3-45a3613ee909.png)
if the SQLWatch-DB from the instance is used:![image](https://user-images.githubusercontent.com/6452224/194310604-43f7f70f-6ba1-472c-a674-7a2f3ba82c58.png)
This is the result from the sqlwatch-query
To me it seems as if the dashboard always shows the last result.
Windows Server (please complete the following information):
SQL Server (please complete the following information):
SQL Server Management Studio (SSMS -> about -> copy info):
SQLWATCH version (from DACPAC or from sysinstances)
Additional context Add any other context about the problem here.