Monday, March 19, 2012

export trace file to excel?

Hi
I would like to export all the information in my trace file to excel so I
can do a sort. Any suggestions on how to do this? I tried the standard copy
and paste method but the data didnt group correctly. Thanks.You can load the data from the trace file to a table using the
fn_trace_gettable system function and then pull the table into Excel.
Normally best done using SELECT INTO for minimal logging. BOL has good
examples for fn_trace_gettable.
HTH,
Plamen Ratchev
http://www.SQLStudio.com|||Theresa,
One possible approach:
1. Save the trace to a table in the database.
2. Use the export wizard to export the table to an Excel spreadsheet.
-- Bill
"Theresa" <Theresa@.discussions.microsoft.com> wrote in message
news:B835165F-8769-4BAB-9EFC-A0C68FF093BF@.microsoft.com...
> Hi
> I would like to export all the information in my trace file to excel so I
> can do a sort. Any suggestions on how to do this? I tried the standard
> copy
> and paste method but the data didnt group correctly. Thanks.|||Hi Theresa
Why don't you load the trace into a SQL Server table? You can sort a table
very easily.
--
HTH
Kalen Delaney, SQL Server MVP
http://sqlblog.com
"Theresa" <Theresa@.discussions.microsoft.com> wrote in message
news:B835165F-8769-4BAB-9EFC-A0C68FF093BF@.microsoft.com...
> Hi
> I would like to export all the information in my trace file to excel so I
> can do a sort. Any suggestions on how to do this? I tried the standard
> copy
> and paste method but the data didnt group correctly. Thanks.|||Thank you!! That works great!
"Plamen Ratchev" wrote:
> You can load the data from the trace file to a table using the
> fn_trace_gettable system function and then pull the table into Excel.
> Normally best done using SELECT INTO for minimal logging. BOL has good
> examples for fn_trace_gettable.
> HTH,
> Plamen Ratchev
> http://www.SQLStudio.com
>
>

No comments:

Post a Comment