Forums before death by AOL, social media and spammers... "We can't have nice things"
|    comp.databases.ms-sqlserver    |    Notorious Rube Goldberg contraption    |    19,505 messages    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
|    Message 17,686 of 19,505    |
|    Erland Sommarskog to Jimbo    |
|    Re: Running Profiler via a SQL script.    |
|    06 Nov 09 23:38:39    |
      b907526f       From: esquel@sommarskog.se              Jimbo (james.goodwill@googlemail.com) writes:       > SQL 2005 Enterprise Edition (SP2)       >       > I'm having trouble running a SQL script generated via the SQL 2005       > Profiler.       >       > I've set up a very simple proifle template to look for 'Crystal       > Report' SQL that runs for over 2 seconds in the mill - the only two       > filters I have on the template are 'Application name' and 'Duration'.       > When I run it in the Profile GUI, all is fine, and I receive the       > expect output.       >       > When I generate a SQL script of the profile template, to run in Query       > Analyser or as a scheduled job, none of the filtering seems to work,       > and I receive data for all SQL running through the mill.       >       > What's wrong? Does anyone have any suggestions?              There was a bug with creating the script in Profiler, so that traces were       not exported correctly. I don't remember when it was fixed, but take a       look at the calls to sp_trace_setfilter at the end of the script, and       verify the calls against the documentation in Books Online.                     --       Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se              Links for SQL Server Books Online:       SQL 2008: http://msdn.microsoft.com/en-us/sqlserver/cc514207.aspx       SQL 2005: http://msdn.microsoft.com/en-us/sqlserver/bb895970.aspx       SQL 2000: http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx              --- SoupGate-Win32 v1.05        * Origin: you cannot sedate... all the things you hate (1:229/2)    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
(c) 1994, bbs@darkrealms.ca