load_SSAS_trace_data.dtsx

Mar 9, 2011 at 2:01 PM

i  have been having trouble using the above package load_SSAS_trace_data.dtsx .

The SCR READ TRACE DATA keep on failing with an error on the script task . Any clues on what can be causing this

 

   at Microsoft.SqlServer.Management.Trace.TraceReader.get_FieldCount()
   at SC_0517b9a45b4f4b3c9c86c11dd9fa4f27.vbproj.ScriptMain.CreateNewOutputRows()
   at SC_0517b9a45b4f4b3c9c86c11dd9fa4f27.vbproj.UserComponent.PrimeOutput(Int32 Outputs, Int32[] OutputIDs, PipelineBuffer[] Buffers)
   at Microsoft.SqlServer.Dts.Pipeline.ScriptComponentHost.PrimeOutput(Int32 outputs, Int32[] outputIDs, PipelineBuffer[] buffers)

Coordinator
Mar 11, 2011 at 4:39 PM

I took at look at this and my guess is that the red line is throwing an error, but the catch statement just absorbs the error so you don't see it. I would add a breakpoint inside the catch and then step through the code to see what error you're getting. Maybe sTraceFileName isn't pointing to a valid trace file or something? Or maybe that trace file is still being written to? My guess is that the exception you're seeing from your post above is from the line I highlighted in blue... so maybe the code above it didn't work as expected.

 

        Dim issuccess As Boolean = True
        Try
            ' Open the trace file as a reader

            myTraceFile.InitializeAsReader(Me.Variables.sTraceFileName)
        Catch goof As Exception
            System.Diagnostics.Trace.WriteLine(goof.InnerException)
            issuccess = False
        End Try


        Dim numfields As Integer = 0

        If myTraceFile.FieldCount >= 1 Then
            numfields = myTraceFile.FieldCount
        Else
            numfields = 17
        End If

Coordinator
Mar 11, 2011 at 4:40 PM

Oops. You can't put a breakpoint on a script component (i.e. a script in the data flow). So maybe just change the code to just throw the error instead of catching it temporarily.

Mar 15, 2011 at 3:19 PM
I figured out the problem, I had to run the package under 32 bit debug mode to make it work

Thanks for your help !


From: [email removed]
To: [email removed]
Date: Fri, 11 Mar 2011 08:39:27 -0800
Subject: Re: load_SSAS_trace_data.dtsx [SQLSrvAnalysisSrvcs:249017]

From: furmangg
I took at look at this and my guess is that the red line is throwing an error, but the catch statement just absorbs the error so you don't see it. I would add a breakpoint inside the catch and then step through the code to see what error you're getting. Maybe sTraceFileName isn't pointing to a valid trace file or something? Or maybe that trace file is still being written to? My guess is that the exception you're seeing from your post above is from the line I highlighted in blue... so maybe the code above it didn't work as expected.

Dim issuccess As Boolean = True
Try
' Open the trace file as a reader
myTraceFile.InitializeAsReader(Me.Variables.sTraceFileName)
Catch goof As Exception
System.Diagnostics.Trace.WriteLine(goof.InnerException)
issuccess = False
End Try

Dim numfields As Integer = 0
If myTraceFile.FieldCount >= 1 Then
numfields = myTraceFile.FieldCount
Else
numfields = 17
End If
Read the full discussion online.
To add a post to this discussion, reply to this email (SQLSrvAnalysisSrvcs@discussions.codeplex.com)
To start a new discussion for this project, email SQLSrvAnalysisSrvcs@discussions.codeplex.com
You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe on CodePlex.com.
Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at CodePlex.com
May 10, 2012 at 12:48 PM

Thanks -

Also run into same problem in W7x64 SSAS 2008R2 on localhost

ps imho woth mentionning in Docs - that shopuld be run under 32 bit

not 64 bit

Oct 5, 2012 at 1:46 PM

Even Iam facing the issue, Is this package is also compataible for ASTRACE Files in 2012. Because Iam getting the similar error when Iam running the package

SCR READ TRACE DATA keep on failing with an error on the script task . Any clues on what can be causing this

 

   at Microsoft.SqlServer.Management.Trace.TraceReader.get_FieldCount()
   at SC_0517b9a45b4f4b3c9c86c11dd9fa4f27.vbproj.ScriptMain.CreateNewOutputRows()
   at SC_0517b9a45b4f4b3c9c86c11dd9fa4f27.vbproj.UserComponent.PrimeOutput(Int32 Outputs, Int32[] OutputIDs, PipelineBuffer[] Buffers)
   at Microsoft.SqlServer.Dts.Pipeline.ScriptComponentHost.PrimeOutput(Int32 outputs, Int32[] outputIDs

Dec 1, 2014 at 11:36 AM
Iam also facing the issue, Is this package is also compataible for ASTRACE Files in 2012. Because Iam getting the similar error when Iam running the package

SCR READ TRACE DATA keep on failing with an error on the script task . Any clues on what can be causing this



at Microsoft.SqlServer.Management.Trace.TraceReader.get_FieldCount()
at SC_0517b9a45b4f4b3c9c86c11dd9fa4f27.vbproj.ScriptMain.CreateNewOutputRows()
at SC_0517b9a45b4f4b3c9c86c11dd9fa4f27.vbproj.UserComponent.PrimeOutput(Int32 Outputs, Int32[] OutputIDs, PipelineBuffer[] Buffers)
at Microsoft.SqlServer.Dts.Pipeline.ScriptComponentHost.PrimeOutput(Int32 outputs, Int32[] outputIDs


I have saved a trc file in my c: drive but
Dim issuccess As Boolean = True
Try
' Open the trace file as a reader
myTraceFile.InitializeAsReader(Me.Variables.sTraceFileName) ---this statement can't read the .trc file
Catch goof As Exception
System.Diagnostics.Trace.WriteLine(goof.InnerException)
issuccess = False
End Try


please help me giving a proper solution