Skip to content

Commit

Permalink
Add missing character replacement to sql_instance tag (#6610)
Browse files Browse the repository at this point in the history
  • Loading branch information
Trovalo authored and danielnelson committed Nov 5, 2019
1 parent 042fa53 commit ba57981
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions plugins/inputs/sqlserver/sqlserver.go
Original file line number Diff line number Diff line change
Expand Up @@ -1305,7 +1305,7 @@ const sqlAzureDBResourceGovernance string = `
IF SERVERPROPERTY('EngineEdition') = 5 -- Is this Azure SQL DB?
SELECT
'sqlserver_db_resource_governance' AS [measurement],
@@servername AS [sql_instance],
REPLACE(@@SERVERNAME,'\',':') AS [sql_instance],
DB_NAME() as [database_name],
slo_name,
dtu_limit,
Expand Down Expand Up @@ -1344,7 +1344,7 @@ BEGIN
IF SERVERPROPERTY('EngineEdition') = 8 -- Is this Azure SQL Managed Instance?
SELECT
'sqlserver_instance_resource_governance' AS [measurement],
@@SERVERNAME AS [sql_instance],
REPLACE(@@SERVERNAME,'\',':') AS [sql_instance],
instance_cap_cpu,
instance_max_log_rate,
instance_max_worker_threads,
Expand All @@ -1367,7 +1367,7 @@ SELECT blocking_session_id into #blockingSessions FROM sys.dm_exec_requests WHE
create index ix_blockingSessions_1 on #blockingSessions (blocking_session_id)
SELECT
'sqlserver_requests' AS [measurement],
@@servername AS [sql_instance],
REPLACE(@@SERVERNAME,'\',':') AS [sql_instance],
DB_NAME() as [database_name],
r.session_id
, r.request_id
Expand Down

0 comments on commit ba57981

Please sign in to comment.