Quantcast
Channel: SQL Server Setup & Upgrade forum
Viewing all articles
Browse latest Browse all 7696

SQL server 2012 Standard report Disk usage – stale data

$
0
0

I have strange problem, where standard report is giving me old data, from several months, but no new data. I can not see any errors.

If I generate standard report fro disk usage, I get old data  from two monts. No new data. If I open trace file, I can see  current data.

If I  run query, I can see current data :

SELECT TE.nameAS[EventName] ,

       T.DatabaseName,

       t.DatabaseID,

       t.NTDomainName,

       t.ApplicationName,

       t.LoginName,

       t.SPID,

       t.Duration,

       t.StartTime,

       t.EndTime

FROM   sys.fn_trace_gettable(CONVERT(VARCHAR(150),(SELECT TOP 1

                                                             f.[value]

                                                     FROM    sys.fn_trace_getinfo(NULL)f

                                                     WHERE   f.property= 2

                                                   )),DEFAULT)T

       JOINsys.trace_eventsTEON T.EventClass=TE.trace_event_id

WHERE  te.name='Data File Auto Grow'

       ORte.name='Data File Auto Shrink'

ORDERBYt.StartTime;

SELECT REVERSE(SUBSTRING(REVERSE(path),CHARINDEX('\',REVERSE(path)), 256))ASDefaultTraceLocation

FROM   sys.traces

WHERE  is_default= 1

But these query gives me, data that I see in the report.

SELECT TE.nameAS[EventName] ,

       T.DatabaseName,

       t.DatabaseID,

       t.NTDomainName,

       t.ApplicationName,

       t.LoginName,

       t.SPID,

       t.Duration,

       t.StartTime,

       t.EndTime

FROM   sys.fn_trace_gettable(CONVERT(VARCHAR(150),(SELECT TOP 1

                                                             f.[value]

                                                     FROM    sys.fn_trace_getinfo(NULL)f

                                                     WHERE   f.property= 2

                                                   )),DEFAULT) T

       JOINsys.trace_eventsTEON T.EventClass=TE.trace_event_id

WHERE  te.name='Data File Auto Grow'

       ORte.name='Data File Auto Shrink'

ORDERBYt.StartTime;

SELECT REVERSE(SUBSTRING(REVERSE(path),CHARINDEX('\',REVERSE(path)), 256))ASDefaultTraceLocation

FROM   sys.traces

WHERE  is_default= 1


Viewing all articles
Browse latest Browse all 7696

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>