Skip to content

Commit

Permalink
data ytpe change in spLoadSchedulerMonitor
Browse files Browse the repository at this point in the history
Change of  c1.value('(./event/data[@name="id"])[1]', 'int') as id,  to c1.value('(./event/data[@name="id"])[1]', 'bigint') as id,
to avoid Overflow errors
  • Loading branch information
Dirk Hondong committed May 12, 2017
1 parent 065b676 commit 1c7c614
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions SQL-Performance-Baseline/CreateSystemhealthDBAndSchema.sql
@@ -1,4 +1,4 @@
/**************************
/**************************
This Sample Code is provided for the purpose of illustration only and is not intended to be used in a production environment. THIS SAMPLE CODE AND ANY RELATED INFORMATION ARE PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A PARTICULAR PURPOSE. We grant You a nonexclusive, royalty-free right to use and modify the Sample Code and to reproduce and distribute the object code form of the Sample Code, provided that You agree: (i) to not use Our name, logo, or trademarks to market Your software product in which the Sample Code is embedded; (ii) to include a valid copyright notice on Your software product in which the Sample Code is embedded; and (iii) to indemnify, hold harmless, and defend Us and Our suppliers from and against any claims or lawsuits, including attorneys’ fees, that arise or result from the use or distribution of the Sample Code.
Author: Denzil Ribeiro
Date: Jan 6, 2013
Expand Down Expand Up @@ -562,7 +562,7 @@ drop table tbl_scheduler_monitor
select
c1.value('(./event/@timestamp)[1]', 'datetime') as UTCtimestamp,
DATEADD(mi,@UTDDateDiff,c1.value('(./event/@timestamp)[1]', 'datetime')) as [timestamp],
c1.value('(./event/data[@name="id"])[1]', 'int') as [id],
c1.value('(./event/data[@name="id"])[1]', 'bigint') as [id],
c1.value('(./event/data[@name="process_utilization"])[1]', 'int') as process_utilization,
c1.value('(./event/data[@name="system_idle"])[1]', 'int') as system_idle,
c1.value('(./event/data[@name="user_mode_time"])[1]', 'bigint') as user_mode_time,
Expand Down Expand Up @@ -774,5 +774,3 @@ select 'Process System Health XEL files from a UNC' as ImportMethod, 'exec spLoa
exec spLoadSystemHealthSession @path_to_health_session='D:\XELFiles\system_health*.xel',@UTDDateDiff=-6
Exec spLoadSystemHealthSession
*/


0 comments on commit 1c7c614

Please sign in to comment.