<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://sqlblogcasts.com/utility/FeedStylesheets/atom.xsl" media="screen"?><feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en"><title type="html">sqlworkshops</title><subtitle type="html" /><id>http://sqlblogcasts.com/blogs/sqlworkshops/atom.aspx</id><link rel="alternate" type="text/html" href="http://sqlblogcasts.com/blogs/sqlworkshops/default.aspx" /><link rel="self" type="application/atom+xml" href="http://sqlblogcasts.com/blogs/sqlworkshops/atom.aspx" /><generator uri="http://communityserver.org" version="3.1.20917.1142">Community Server</generator><updated>2007-11-25T19:30:00Z</updated><entry><title>Download Level 400 SQL Server Webcast 3, FREE, for limited time, download ASAP from webcasts.sqlworkshops.com</title><link rel="alternate" type="text/html" href="http://sqlblogcasts.com/blogs/sqlworkshops/archive/2010/02/10/download-level-400-sql-server-webcast-3-free-for-limited-time-download-asap-from-webcasts-sqlworkshops-com.aspx" /><id>http://sqlblogcasts.com/blogs/sqlworkshops/archive/2010/02/10/download-level-400-sql-server-webcast-3-free-for-limited-time-download-asap-from-webcasts-sqlworkshops-com.aspx</id><published>2010-02-10T16:36:00Z</published><updated>2010-02-10T16:36:00Z</updated><content type="html">
&lt;p&gt;&lt;br /&gt;You can NOW download the FULL Level 400 SQL Server Webcasts 3 from &lt;a href="http://www.sqlworkshops.com/webcasts"&gt;&lt;strong&gt;http://www.sqlworkshops.com/webcasts&lt;/strong&gt;&lt;/a&gt;, FREE, no registration necessary.&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;Webcast 3 Part 1: &lt;a href="http://sqlworkshops.box.net/shared/static/gu6ysh15cc.wmv"&gt;&lt;strong&gt;http://sqlworkshops.box.net/shared/static/gu6ysh15cc.wmv&lt;/strong&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;Webcast 3 Part 2: &lt;a href="http://sqlworkshops.box.net/shared/static/690b473f4j.wmv"&gt;&lt;strong&gt;http://sqlworkshops.box.net/shared/static/690b473f4j.wmv&lt;/strong&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;Webcast 3 Part 3: &lt;a href="http://sqlworkshops.box.net/shared/static/g4t0o05nu5.wmv"&gt;&lt;strong&gt;http://sqlworkshops.box.net/shared/static/g4t0o05nu5.wmv&lt;/strong&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;Pass on the link to your SQL Server friends and colleagues.&lt;/p&gt;
&lt;p&gt;&lt;br /&gt;R Meyyappan&lt;/p&gt;
&lt;p&gt;&lt;a href="http://www.sqlworkshops.com/"&gt;ww.sqlworkshops.com&lt;/a&gt;&lt;/p&gt;&lt;img src="http://sqlblogcasts.com/aggbug.aspx?PostID=13035" width="1" height="1"&gt;</content><author><name>sqlworkshops</name><uri>http://sqlblogcasts.com/members/sqlworkshops.aspx</uri></author></entry><entry><title>FREE Level 400 Webcast 3 on Tuning Parallelism (CXPACKET, SLEEP_TASK), Hash Match (SLEEP_TASK), Sort (IO_COMPLETION), Prefetch (PAGEIOLATCH_SH)</title><link rel="alternate" type="text/html" href="http://sqlblogcasts.com/blogs/sqlworkshops/archive/2010/02/08/free-level-400-webcast-3-on-tuning-parallelism-cxpacket-sleep-task-hash-match-sleep-task-sort-io-completion-prefetch-pageiolatch-sh.aspx" /><id>http://sqlblogcasts.com/blogs/sqlworkshops/archive/2010/02/08/free-level-400-webcast-3-on-tuning-parallelism-cxpacket-sleep-task-hash-match-sleep-task-sort-io-completion-prefetch-pageiolatch-sh.aspx</id><published>2010-02-08T17:28:00Z</published><updated>2010-02-08T17:28:00Z</updated><content type="html">
&lt;p&gt;Download (FREE!) Truly Level 400 SQL Server Performance Monitoring and Tuning Webcast 3 for developers and database administrators from &lt;a href="http://webcasts.sqlworkshops.com/"&gt;&lt;strong&gt;http://webcasts.sqlworkshops.com&lt;/strong&gt;&lt;/a&gt;. Preview, full webcast will be available for download coming Wednesday around noon PST. Please forward the link to your friends and local user community.&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Webcast 3&lt;/strong&gt;: Recommends not using stored procedure or other plan caching mechanism like using sp_executesql and Prepared Statement using ADO.NET or OLEDB based executions for memory allocating queries. Common memory allocating queries are that perform Sort and do Hash Match operations like Hash Join or Hash Aggregation or Hash Union.&lt;br /&gt;&lt;br /&gt;With examples provides ways to identify queries performing Hash match operations that spill to tempdb. Using SQL Profiler: Hash Warnings (Hash Recursion and Hash Bailout). Using sys.dm_exec_query_memory_grants: Granted Memory, Used Memory and Maximum Used memory. Explains how SLEEP_TASK wait type is associated with Sort Warnings.&lt;br /&gt;&lt;br /&gt;Explains with examples how sp_recompile can block and bring an application to a standstill and recommends using DBCC FREEPROCCACHE (plan_handle) instead.&lt;br /&gt;&lt;br /&gt;Explains with examples how stored procedure or other plan caching mechanism affects queries that sort (perform order by). Explains how IO_COMPLETION wait type is associated with Sort Warnings.&lt;br /&gt;&lt;br /&gt;Demonstrates why rollbacks and database restore could wait on IO_COMPLETION wait type and if needed how this wait can be reduced.&lt;br /&gt;&lt;br /&gt;Explains how parallel query performance is significantly affected by a CPU intensive query executing on one of the CPU cores. Explains the reason for the performance issue and how to identify the issue. With example explains the reason for the observed query execution time when the child thread executes on the CPU core where the CPU intensive query executes and also when the coordinator executes on the CPU core where the CPU intensive query executes. Recommends ways to avoid this parallel query performance issue and also demonstrates that only certain queries will be affected by this and not all parallel queries.&lt;br /&gt;Explains sys.dm_os_waits_stats.signal_wait_time_ms does not indicate system wide CPU pressure, just at a CPU core level.&lt;br /&gt;&lt;br /&gt;Explains the prefetch mechanism and how it can affect query performance. Provides ways to force prefecth. Demonstrates cases where Avg. Disk Sec / read, the disk latency, PAGEIOLATCH_SH, Avg. disk queue length is very high and the query executes fast.&lt;br /&gt;&lt;br /&gt;Explains why Plan Guides (Plan Freezing!) cannot help with prefetch or in few other cases.&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Webcast 2&lt;/strong&gt;: Explains high CXPACKET waits are NOT a direct result of delays associated with inefficiencies of parallel processing. Provides example to scale queries over many CPU cores without reducing MAXDOP settings.&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Webcast 1&lt;/strong&gt;: Explains Memory allocation issues with sort. Demonstrates ways to identify sort spills to tempdb. Provides query rewrite procedure to avoid sort spills to tempdb. Demonstrates cases where 1 tempdb date file per core might not be ideal for all implementations.&lt;br /&gt;&lt;br /&gt;Regards&lt;br /&gt;&lt;br /&gt;R Meyyappan&lt;br /&gt;&lt;a href="http://www.sqlworkshops.com/"&gt;&lt;strong&gt;http://www.sqlworkshops.com&lt;/strong&gt;&lt;/a&gt;&lt;/p&gt;&lt;img src="http://sqlblogcasts.com/aggbug.aspx?PostID=13004" width="1" height="1"&gt;</content><author><name>sqlworkshops</name><uri>http://sqlblogcasts.com/members/sqlworkshops.aspx</uri></author></entry><entry><title>Download Now Free Truly Level 400 SQL Server Performance Tuning Webcast 2 at SQLWorkshops.com</title><link rel="alternate" type="text/html" href="http://sqlblogcasts.com/blogs/sqlworkshops/archive/2010/01/20/download-free-truly-level-400-sql-server-performance-tuning-webcast-2-at-sqlworkshops-com.aspx" /><id>http://sqlblogcasts.com/blogs/sqlworkshops/archive/2010/01/20/download-free-truly-level-400-sql-server-performance-tuning-webcast-2-at-sqlworkshops-com.aspx</id><published>2010-01-20T13:08:00Z</published><updated>2010-01-20T13:08:00Z</updated><content type="html">&lt;font size="3"&gt;&lt;span style="FONT-FAMILY:&amp;#39;Calibri&amp;#39;,&amp;#39;sans-serif&amp;#39;;COLOR:#1f497d;mso-bidi-font-family:Arial;"&gt;Thanks for everyone who attended my level 400 SQLBits session and viewed Webcast 1, due to great feedback here is Webcast 2. This level 400 SQL Server Tuning&amp;nbsp;webcast covers optimizing queries to scale across many CPU cores (by addressing inefficiencies in parallel query execution without reducing MAXDOP due to high CXPACKET waits). Liked Webcast 1 ? you will like Webcast 2 even more!!&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style="FONT-FAMILY:&amp;#39;Arial&amp;#39;,&amp;#39;sans-serif&amp;#39;;COLOR:black;FONT-SIZE:10pt;"&gt;&lt;/span&gt;&lt;/font&gt;&lt;span style="FONT-FAMILY:&amp;#39;Arial&amp;#39;,&amp;#39;sans-serif&amp;#39;;COLOR:#1f497d;FONT-SIZE:10pt;"&gt;&lt;a href="http://webcasts.sqlworkshops.com/"&gt;&lt;span style="FONT-FAMILY:&amp;#39;Calibri&amp;#39;,&amp;#39;sans-serif&amp;#39;;FONT-SIZE:12pt;"&gt;&lt;strong&gt;http://webcasts.sqlworkshops.com&lt;/strong&gt;&lt;/span&gt;&lt;/a&gt;&lt;/span&gt;&lt;span style="FONT-FAMILY:&amp;#39;Arial&amp;#39;,&amp;#39;sans-serif&amp;#39;;COLOR:black;FONT-SIZE:10pt;"&gt;&lt;/span&gt;&lt;font size="3"&gt;&lt;span style="FONT-FAMILY:&amp;#39;Calibri&amp;#39;,&amp;#39;sans-serif&amp;#39;;COLOR:#1f497d;mso-bidi-font-family:Arial;"&gt;&lt;br /&gt;&lt;br /&gt;Previous webcast covered optimizing queries to avoid sort spills over tempdb (by addressing memory grant issues). Next webcast will cover optimizing queries to efficiently utilize Disk subsystem (planned release date February 10, 2010).&lt;/span&gt;&lt;span style="FONT-FAMILY:&amp;#39;Arial&amp;#39;,&amp;#39;sans-serif&amp;#39;;COLOR:black;FONT-SIZE:10pt;"&gt;&lt;/span&gt;&lt;/font&gt;&lt;span style="COLOR:#1f497d;"&gt;&lt;font size="3" face="Calibri"&gt;&lt;br /&gt;&lt;br /&gt;Feedback from a Microsoft Employee on Webcast 1: &amp;quot;Your webcast rocked. Your free webcast was very good and informative&amp;quot;.&lt;/font&gt;&lt;/span&gt;&lt;span style="FONT-FAMILY:&amp;#39;Times New Roman&amp;#39;,&amp;#39;serif&amp;#39;;COLOR:black;FONT-SIZE:12pt;"&gt;&amp;nbsp;&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;font size="3" face="Calibri"&gt;&lt;span style="COLOR:red;mso-bidi-font-family:Arial;"&gt;In case you made a resolution this New Year to gain deep SQL Server knowledge, here is an opportunity knocking at your door, don’t miss it, it is all FREE, it costs you nothing&lt;/span&gt;&lt;span style="COLOR:#e36c0a;mso-bidi-font-family:Arial;"&gt;.&lt;/span&gt;&lt;/font&gt;&lt;span style="COLOR:#e36c0a;mso-bidi-font-family:Arial;"&gt;&lt;font size="3" face="Calibri"&gt;&amp;nbsp;&lt;/font&gt;&lt;/span&gt;&lt;span style="COLOR:#1f497d;mso-bidi-font-family:Arial;"&gt;&lt;font size="3" face="Calibri"&gt;&lt;br /&gt;&lt;br /&gt;These webcasts are equally designed for developers and database administrators. We believe with deep SQL Server knowledge customers can reduce Total Cost of Ownership (&lt;b&gt;TCO&lt;/b&gt;) without investing in additional hardware or software, by simply optimizing their existing investment.&lt;/font&gt;&lt;/span&gt;&lt;span style="FONT-FAMILY:&amp;#39;Arial&amp;#39;,&amp;#39;sans-serif&amp;#39;;COLOR:black;FONT-SIZE:10pt;"&gt; &lt;/span&gt;&lt;span style="COLOR:#e36c0a;mso-bidi-font-family:Arial;"&gt;&lt;/span&gt;&lt;font size="3"&gt;&lt;span style="FONT-FAMILY:&amp;#39;Calibri&amp;#39;,&amp;#39;sans-serif&amp;#39;;COLOR:#1f497d;mso-bidi-font-family:Arial;"&gt;&lt;br /&gt;&lt;br /&gt;Like before, these webcasts are full of real world examples and not a power point slide bullet point based best practice guideline lectures. These webcasts are a result of practical performance tuning for real world customer issues. We are sure you will find them useful in your day to day work. &lt;/span&gt;&lt;span style="FONT-FAMILY:&amp;#39;Arial&amp;#39;,&amp;#39;sans-serif&amp;#39;;COLOR:black;FONT-SIZE:10pt;"&gt;&lt;/span&gt;&lt;/font&gt;&lt;span style="COLOR:#1f497d;mso-bidi-font-family:Arial;"&gt;&lt;font size="3" face="Calibri"&gt;&lt;br /&gt;&lt;br /&gt;Hope you enjoy our freely downloadable webcasts; I am looking forward to your feedback&lt;/font&gt;&lt;/span&gt;&lt;span style="COLOR:#1f497d;mso-bidi-font-family:Arial;"&gt;&lt;font size="3" face="Calibri"&gt;&amp;nbsp;&lt;/font&gt;&lt;font size="3" face="Calibri"&gt;&lt;br /&gt;&lt;br /&gt;Regards&lt;/font&gt;&lt;/span&gt;&lt;span style="FONT-FAMILY:&amp;#39;Arial&amp;#39;,&amp;#39;sans-serif&amp;#39;;COLOR:black;FONT-SIZE:10pt;"&gt; &lt;/span&gt;&lt;span style="COLOR:#1f497d;FONT-SIZE:12pt;mso-bidi-font-family:Arial;"&gt;&lt;/span&gt;&lt;font size="3"&gt;&lt;span style="FONT-FAMILY:&amp;#39;Calibri&amp;#39;,&amp;#39;sans-serif&amp;#39;;COLOR:#1f497d;mso-bidi-font-family:Arial;"&gt;&lt;br /&gt;-ramesh-&lt;br /&gt;&lt;a href="http://www.sqlworkshops.com/"&gt;http://www.sqlworkshops.com/&lt;/a&gt;&lt;br /&gt;&lt;/span&gt;&lt;/font&gt;&lt;span style="COLOR:#1f497d;"&gt;&lt;font color="#800080" size="3" face="Calibri"&gt;&lt;a href="http://www.sqlbits.com/Speakers/R_Meyyappan/Default.aspx"&gt;http://www.sqlbits.com/Speakers/R_Meyyappan/Default.aspx&lt;/a&gt;&lt;/font&gt;&lt;/span&gt;&lt;span style="FONT-FAMILY:&amp;#39;Times New Roman&amp;#39;,&amp;#39;serif&amp;#39;;COLOR:black;FONT-SIZE:12pt;"&gt;&lt;/span&gt;&lt;span style="COLOR:#1f497d;"&gt;&lt;font size="3" face="Calibri"&gt;&lt;/font&gt;&lt;/span&gt;&lt;img src="http://sqlblogcasts.com/aggbug.aspx?PostID=12894" width="1" height="1"&gt;</content><author><name>sqlworkshops</name><uri>http://sqlblogcasts.com/members/sqlworkshops.aspx</uri></author><category term="SQLBits" scheme="http://sqlblogcasts.com/blogs/sqlworkshops/archive/tags/SQLBits/default.aspx" /><category term="Performance" scheme="http://sqlblogcasts.com/blogs/sqlworkshops/archive/tags/Performance/default.aspx" /></entry><entry><title>For those who couldn't attend my session - Let’s make SQL fly @ SQLBits V</title><link rel="alternate" type="text/html" href="http://sqlblogcasts.com/blogs/sqlworkshops/archive/2009/12/02/fot-those-who-couldn-t-attend-my-session-let-s-make-sql-fly-during-sqlbits-v.aspx" /><id>http://sqlblogcasts.com/blogs/sqlworkshops/archive/2009/12/02/fot-those-who-couldn-t-attend-my-session-let-s-make-sql-fly-during-sqlbits-v.aspx</id><published>2009-12-02T15:17:00Z</published><updated>2009-12-02T15:17:00Z</updated><content type="html">&lt;p&gt;Here is the link to the content in the webcast format&lt;/p&gt;
&lt;p&gt;&lt;a href="http://webcasts.sqlworkshops.com/"&gt;http://webcasts.sqlworkshops.com&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Regards&lt;/p&gt;
&lt;p&gt;-ramesh-&lt;/p&gt;&lt;img src="http://sqlblogcasts.com/aggbug.aspx?PostID=12668" width="1" height="1"&gt;</content><author><name>sqlworkshops</name><uri>http://sqlblogcasts.com/members/sqlworkshops.aspx</uri></author><category term="SQLBits.com" scheme="http://sqlblogcasts.com/blogs/sqlworkshops/archive/tags/SQLBits.com/default.aspx" /></entry><entry><title>dm_exec_query_stats reports wrong CPU Utilization when a query executes in parallel(MAXDOP &gt; 1)</title><link rel="alternate" type="text/html" href="http://sqlblogcasts.com/blogs/sqlworkshops/archive/2007/12/07/dm-exec-query-stats-reports-wrong-cpu-utilization-when-a-query-executes-in-parallel-maxdop-1.aspx" /><id>http://sqlblogcasts.com/blogs/sqlworkshops/archive/2007/12/07/dm-exec-query-stats-reports-wrong-cpu-utilization-when-a-query-executes-in-parallel-maxdop-1.aspx</id><published>2007-12-07T07:37:00Z</published><updated>2007-12-07T07:37:00Z</updated><content type="html">&lt;P&gt;&lt;STRONG&gt;&lt;FONT size=2&gt;Introduction:&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT size=2&gt;&lt;BR&gt;This article helps you to understand the fact that sys.dm_exec_query_stats returns incorrect CPU utilization when a query executes in parallel.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT size=2&gt;The purpose of this article is to help you better understand SQL Server 2005 Performance Monitoring and Tuning. The purpose of this article is not to discuss whether this is a bug or not.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;&lt;FONT size=2&gt;Description:&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT size=2&gt;&lt;BR&gt;When a query executes serially(MAXDOP&amp;nbsp; = 1), the total_worker_time reported in sys.dm_exec_query_stats is accurate. But when a query executes in parallel(MAXDOP &amp;gt; 1), total_worker_time reported by sys.dm_exec_query_stats is inaccurate.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT size=2&gt;Usually CPU intensive query execute in parallel. Most customer use default configuration where 'max degree of parallelism' is set to '0' where it is more common for CPU intensive queries to execute in parallel.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT size=2&gt;When a customer tell you they has high CPU utilization on their server and ask you to identify the issue. Without knowing sys.dm_exec_query_stats reports incorrect CPU utilization when a query executes in parallel, you might query sys.dm_exec_query_stats and tell your customer that there is no query that is CPU intensive. Sooner or later the customer might find out the query that you missed to point out.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;&lt;FONT size=2&gt;Example:&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT size=2&gt;&lt;BR&gt;This example needs tables that you have to create. The script to create the table is located at the end of this article(&lt;A href="http://www.sqlworkshops.com/dm_exec_query_stats.htm"&gt;&lt;U&gt;&lt;FONT color=#214d7b&gt;www.sqlworkshops.com/dm_exec_query_stats.htm&lt;/FONT&gt;&lt;/U&gt;&lt;/A&gt;). You also need a server that has minimum 2 CPUs to reproduce this example.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT size=2&gt;When you execute the below query limiting MAXDOP to 1(seriel execution), the CPU_Utilized_in_Seconds reported by sys.dm_exec_query_stats is accurate - will match your wall clock execution time.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT size=2&gt;&lt;B&gt;&amp;gt;&amp;gt; in theory sys.dm_exec_qyery_stats always works:&lt;/B&gt;&lt;BR&gt;&lt;/FONT&gt;&lt;FONT color=#008000 size=2&gt;--example provided by &lt;A href="http://www.sqlworkshops.com/"&gt;&lt;FONT color=#214d7b&gt;www.sqlworkshops.com&lt;BR&gt;&lt;/FONT&gt;&lt;/A&gt;--reset cache to collect fresh set of statistics&lt;BR&gt;&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;dbcc&lt;/FONT&gt;&lt;FONT size=2&gt; freeproccache&lt;BR&gt;go&lt;BR&gt;&lt;/FONT&gt;&lt;FONT color=#008000 size=2&gt;--execute a sample workload serially that takes x amount of seconds&lt;BR&gt;&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;select&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#ff00ff size=2&gt;max&lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;(&lt;/FONT&gt;&lt;FONT size=2&gt;t1&lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;.&lt;/FONT&gt;&lt;FONT size=2&gt;c2 &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;+&lt;/FONT&gt;&lt;FONT size=2&gt; t2&lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;.&lt;/FONT&gt;&lt;FONT size=2&gt;c2&lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;)&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;from&lt;/FONT&gt;&lt;FONT size=2&gt; tab7 t1 &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;cross&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;join&lt;/FONT&gt;&lt;FONT size=2&gt; tab7 t2 &lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;option&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;(&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;maxdop&lt;/FONT&gt;&lt;FONT size=2&gt; 1&lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;)&lt;BR&gt;&lt;/FONT&gt;&lt;FONT size=2&gt;go&lt;BR&gt;&lt;/FONT&gt;&lt;FONT color=#008000 size=2&gt;--now query sys.dm_exec_query_stats to find CPU Utilized by the above query&lt;BR&gt;&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;select&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;(&lt;/FONT&gt;&lt;FONT size=2&gt;total_worker_time &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;*&lt;/FONT&gt;&lt;FONT size=2&gt; 1.0&lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;)&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;/&lt;/FONT&gt;&lt;FONT size=2&gt; 1000000 &lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;as&lt;/FONT&gt;&lt;FONT size=2&gt; CPU_Utilized_in_Seconds&lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;,&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;*&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;from&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#008000 size=2&gt;sys.dm_exec_query_stats&lt;BR&gt;&lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;cross&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;apply&lt;/FONT&gt;&lt;FONT size=2&gt; sys.dm_exec_sql_text&lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;(&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;sql_handle&lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;)&lt;BR&gt;&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;where&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;text&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;like&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#ff0000 size=2&gt;'%select max(t1.c2 + t2.c2) from tab7 t1 cross join tab7 t2%'&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;and&lt;BR&gt;&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;text&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;not&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;like&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#ff0000 size=2&gt;'%sys.dm_exec_query_stats%' &lt;/FONT&gt;&lt;FONT color=#008000 size=2&gt;--to eliminate our probe&lt;/FONT&gt;&lt;FONT color=#ff0000 size=2&gt;&lt;BR&gt;&lt;/FONT&gt;&lt;FONT size=2&gt;go&lt;BR&gt;&lt;B&gt;&amp;gt;&amp;gt; CPU_Utilized_in_Seconds will be around 6 to 18 seconds based on your CPU speed - which is what you expect&lt;/B&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT size=2&gt;But when you execute the query without limiting MAXDOP to 1, say 0(parallel execution), the CPU_Utilized_in_Seconds reported by sys.dm_exec_query_stats is inaccurate - will not match your wall clock execution time.&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;FONT size=2&gt;&lt;B&gt;&amp;gt;&amp;gt; in practice sys.dm_exec_qyery_stats does not always works:&lt;/B&gt;&lt;BR&gt;&lt;/FONT&gt;&lt;FONT color=#008000 size=2&gt;--example provided by &lt;A href="http://www.sqlworkshops.com/"&gt;&lt;FONT color=#214d7b&gt;www.sqlworkshops.com&lt;BR&gt;&lt;/FONT&gt;&lt;/A&gt;--reset cache to collect fresh set of statistics&lt;BR&gt;&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;dbcc&lt;/FONT&gt;&lt;FONT size=2&gt; freeproccache&lt;BR&gt;go&lt;BR&gt;&lt;/FONT&gt;&lt;FONT color=#008000 size=2&gt;--execute a sample workload parallely that takes x amount of seconds&lt;BR&gt;&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;select&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#ff00ff size=2&gt;max&lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;(&lt;/FONT&gt;&lt;FONT size=2&gt;t1&lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;.&lt;/FONT&gt;&lt;FONT size=2&gt;c2 &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;+&lt;/FONT&gt;&lt;FONT size=2&gt; t2&lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;.&lt;/FONT&gt;&lt;FONT size=2&gt;c2&lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;)&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;from&lt;/FONT&gt;&lt;FONT size=2&gt; tab7 t1 &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;cross&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;join&lt;/FONT&gt;&lt;FONT size=2&gt; tab7 t2&lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;&lt;BR&gt;&lt;/FONT&gt;&lt;FONT size=2&gt;go&lt;BR&gt;&lt;/FONT&gt;&lt;FONT color=#008000 size=2&gt;--now query sys.dm_exec_query_stats to find CPU Utilized by the above query&lt;BR&gt;&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;select&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;(&lt;/FONT&gt;&lt;FONT size=2&gt;total_worker_time &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;*&lt;/FONT&gt;&lt;FONT size=2&gt; 1.0&lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;)&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;/&lt;/FONT&gt;&lt;FONT size=2&gt; 1000000 &lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;as&lt;/FONT&gt;&lt;FONT size=2&gt; CPU_Utilized_in_Seconds&lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;,&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;*&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;from&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#008000 size=2&gt;sys.dm_exec_query_stats&lt;BR&gt;&lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;cross&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;apply&lt;/FONT&gt;&lt;FONT size=2&gt; sys.dm_exec_sql_text&lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;(&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;sql_handle&lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;)&lt;BR&gt;&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;where&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;text&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;like&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#ff0000 size=2&gt;'%select max(t1.c2 + t2.c2) from tab7 t1 cross join tab7 t2%'&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;and&lt;BR&gt;&lt;/FONT&gt;&lt;FONT color=#0000ff size=2&gt;text&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;not&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#808080 size=2&gt;like&lt;/FONT&gt;&lt;FONT size=2&gt; &lt;/FONT&gt;&lt;FONT color=#ff0000 size=2&gt;'%sys.dm_exec_query_stats%' &lt;/FONT&gt;&lt;FONT color=#008000 size=2&gt;--to eliminate our probe&lt;/FONT&gt;&lt;FONT color=#ff0000 size=2&gt;&lt;BR&gt;&lt;/FONT&gt;&lt;FONT size=2&gt;go&lt;BR&gt;&lt;B&gt;&amp;gt;&amp;gt; CPU_Utilized_in_Seconds will be around 0.00xxxx seconds&amp;nbsp; - which you do not expect!&lt;/B&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&lt;STRONG&gt;The full article is located at &lt;/STRONG&gt;&lt;A title=http://www.sqlworkshops.com/dm_exec_query_stats.htm href="http://www.sqlworkshops.com/dm_exec_query_stats.htm"&gt;&lt;STRONG&gt;www.sqlworkshops.com/dm_exec_query_stats.htm&lt;/STRONG&gt;&lt;/A&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&amp;nbsp;&lt;/P&gt;
&lt;P align=left&gt;Now you see the theoretical explanation and practical usage!!&lt;/P&gt;
&lt;P align=left&gt;&lt;BR&gt;&amp;nbsp;&lt;/P&gt;
&lt;P class=MsoNormal&gt;sqlworkshops / &lt;A href="http://www.sqlworkshops.com/"&gt;www.sqlworkshops.com&lt;/A&gt;&lt;/P&gt;
&lt;P class=MsoNormal&gt;&amp;nbsp;&lt;/P&gt;&lt;img src="http://sqlblogcasts.com/aggbug.aspx?PostID=5288" width="1" height="1"&gt;</content><author><name>sqlworkshops</name><uri>http://sqlblogcasts.com/members/sqlworkshops.aspx</uri></author></entry><entry><title>Finding optimal number of CPUs for a given long running CPU intensive DSS/OLAP like queries/workload</title><link rel="alternate" type="text/html" href="http://sqlblogcasts.com/blogs/sqlworkshops/archive/2007/11/25/finding-optimal-number-of-cpus-for-a-given-long-running-cpu-intensive-dss-olap-like-queries-workload.aspx" /><id>http://sqlblogcasts.com/blogs/sqlworkshops/archive/2007/11/25/finding-optimal-number-of-cpus-for-a-given-long-running-cpu-intensive-dss-olap-like-queries-workload.aspx</id><published>2007-11-25T19:30:00Z</published><updated>2007-11-25T19:30:00Z</updated><content type="html">&lt;P&gt;&lt;STRONG&gt;&lt;FONT size=2&gt;Introduction:&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT size=2&gt;&lt;BR&gt;This article is applicable for finding optimal number of CPUs for long running CPU intensive queries/workload that doesn’t frequently wait for other resources (typical DSS/OLAP workload).&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT size=2&gt;This article is not applicable if your queries/workload is often waiting for resources(like I/Os, Locks, Latches etc.) without consuming CPU in a stretch(typical OLTP workload).&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT size=2&gt;This article can also provide information on uneven CPU load across NUMA nodes and uneven CPU load within same NUMA node (load_factor effect).&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT size=2&gt;It is recommended to analyze Windows Performance Monitor Counters for monitoring CPU pressure. Processor utilization greater then 75% to 80% indicates CPU pressure. Using Windows Performance Monitor should be the 1st step, the procedure suggested in this article should be considered as an additional step.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT size=2&gt;It is very important to find ways to optimize the queries/workload by tuning the database schema before attempting to add additional CPUs.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;&lt;FONT size=2&gt;Description:&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT size=2&gt;&lt;BR&gt;When a customer asks you: I am running a DSS/OLAP like SQL job and it takes x amount of time, how can I reduce the time so the SQL job completes sooner, can I add more CPUs ? if yes, how many ? – this article will help you answer their question.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT size=2&gt;When you see CPU pressure, there are 2 options: you can either upgrade to faster CPUs or add additional CPUs. Upgrading to faster CPU will always help. Adding additional CPUs may not always help the SQL job to run faster unless that SQL job can take advantage of additional CPUs. If the customer already has the fastest CPUs available in the market then they have to wait for the next release of faster CPUs. More practical way might be to add additional CPUs if it helps, the below procedure will help you identify if this is the case.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT size=2&gt;This method calculates total user waits for CPU during the SQL workload and suggests additional CPUs if necessary. If CPU usage is at 100%, but no one waited for CPU during the workload, then adding additional CPU will not help; this is the basics of this calculation.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT size=2&gt;Current recommendations that are available on this topic calculates ‘signal wait time’ to ‘wait time’ ratio to suggest CPU pressure – but this cannot help one easily identify number of additional CPUs necessary.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;&lt;FONT size=2&gt;Procedure:&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT size=2&gt;&lt;BR&gt;When concurrent users apply simultaneous DSS/OLAP like CPU intensive workload, there could be CPU pressure. We can conclude presence of CPU pressure when at any given moment during this time period at least one or more user tasks waited for CPU resource.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT size=2&gt;In this case one can run the below query to find out how many CPU on an average will help to scale the workload better. It might be more informative to collect the below information in short time intervals (many samples) than just once to understand during which time of the workload application the CPU pressure was the most. Single sample will lead to average additional CPUs necessary for the entire workload duration.&lt;/FONT&gt;&lt;/P&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;&lt;FONT size=2&gt;1. Reset Wait Stats&lt;BR&gt;&lt;/FONT&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;FONT-FAMILY:Courier New;"&gt;dbcc&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:Courier New;"&gt; sqlperf&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:Courier New;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:red;FONT-FAMILY:Courier New;"&gt;'sys.dm_os_wait_stats'&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:Courier New;"&gt;,&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:Courier New;"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;FONT-FAMILY:Courier New;"&gt;clear&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:Courier New;"&gt;)&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT size=2&gt;2. Apply workload (you can find sample workload query at the end of this article, you need to execute the sample workload query simultaneously in many sessions to simulate concurrent user tasks).&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT size=2&gt;3. Run the below query to find Additional CPUs Necessary – it is important to run the query right after the workload completes to get reliable information.&lt;BR&gt;&lt;/FONT&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;FONT-FAMILY:'Courier New';"&gt;select&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:fuchsia;FONT-FAMILY:'Courier New';"&gt;round&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;(((&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:fuchsia;FONT-FAMILY:'Courier New';"&gt;convert&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;(&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;FONT-FAMILY:'Courier New';"&gt;float&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;,&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; ws&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;.&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt;wait_time_ms&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;)&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;/&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; ws&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;.&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt;waiting_tasks_count&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;)&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;/&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;(&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:fuchsia;FONT-FAMILY:'Courier New';"&gt;convert&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;(&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;FONT-FAMILY:'Courier New';"&gt;float&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;,&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; si&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;.&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt;os_quantum&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;)&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;/&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; si&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;.&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt;cpu_ticks_in_ms&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;)&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;*&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; cpu_count&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;),&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; 2&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;)&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;FONT-FAMILY:'Courier New';"&gt;as&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; Additional_CPUs_Necessary&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;,&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:fuchsia;FONT-FAMILY:'Courier New';"&gt;round&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;((((&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:fuchsia;FONT-FAMILY:'Courier New';"&gt;convert&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;(&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;FONT-FAMILY:'Courier New';"&gt;float&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;,&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; ws&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;.&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt;wait_time_ms&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;)&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;/&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; ws&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;.&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt;waiting_tasks_count&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;)&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;/&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;(&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:fuchsia;FONT-FAMILY:'Courier New';"&gt;convert&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;(&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;FONT-FAMILY:'Courier New';"&gt;float&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;,&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; si&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;.&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt;os_quantum&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;)&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;/&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; si&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;.&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt;cpu_ticks_in_ms&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;)&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;*&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; cpu_count&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;)&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;/&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; hyperthread_ratio&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;),&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; 2&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;)&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;FONT-FAMILY:'Courier New';"&gt;as&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; Additional_Sockets_Necessary &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;FONT-FAMILY:'Courier New';"&gt;from&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:green;FONT-FAMILY:'Courier New';"&gt;sys.dm_os_wait_stats&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; ws &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;cross&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;apply&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:green;FONT-FAMILY:'Courier New';"&gt;sys.dm_os_sys_info&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; si &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:blue;FONT-FAMILY:'Courier New';"&gt;where&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; ws&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;.&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt;wait_type &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:gray;FONT-FAMILY:'Courier New';"&gt;=&lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:black;FONT-FAMILY:'Courier New';"&gt; &lt;/SPAN&gt;&lt;SPAN style="FONT-SIZE:10pt;COLOR:red;FONT-FAMILY:'Courier New';"&gt;'SOS_SCHEDULER_YIELD'&lt;/SPAN&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;STRONG&gt;&lt;FONT size=2&gt;
&lt;P&gt;&lt;STRONG&gt;&lt;FONT size=2&gt;About the article:&lt;/FONT&gt;&lt;/STRONG&gt;&lt;FONT size=2&gt;&lt;BR&gt;This is an excerpt from the &lt;STRONG&gt;&lt;A class="" title="3 Day Level 400 Microsoft SQL Server 2005 Performance Monitoring &amp;amp; Tuning Workshop" href="http://www.sqlworkshops.com/workshops.htm"&gt;&lt;FONT color=#03664b&gt;3 Day Level 400 Microsoft SQL Server 2005 Performance Monitoring and Tuning Workshop&lt;/FONT&gt;&lt;/A&gt;&lt;/STRONG&gt;; I explain the concepts in the workshop with examples. I try to do the best while writing this article, but it is not the same!!&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT size=2&gt;This articles discusses a way to find optimal number of CPUs for a given long running CPU intensive DSS/OLAP like queries/workload by measuring CPU pressure. The articles applies to a specific kind of workload, apply the concepts carefully. &lt;BR&gt;&lt;BR&gt;If you find this article helpful, give me feedback, this motivates me to write some more articles. I also encourage you attending the &lt;STRONG&gt;&lt;A class="" title="3 Day Level 400 Microsoft SQL Server 2005 Performance Monitoring and Tuning Workshop" href="http://www.sqlworkshops.com/workshops.htm"&gt;&lt;FONT color=#03664b&gt;3 Day Level 400 Microsoft SQL Server 2005 Performance Monitoring and Tuning Workshop&lt;/FONT&gt;&lt;/A&gt;&lt;/STRONG&gt;, the content is very unique &amp;amp; authentic, in addition it is useful, deep and I provide very accurate information with extraordinary attention to detail and explain in depth the internals.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;The complete article is located at:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;A class="" title="CPU Pressure" href="http://www.sqlworkshops.com/cpupressure.htm"&gt;CPU Pressure&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://www.sqlworkshops.com/"&gt;www.sqlworkshops.com&lt;/A&gt;&lt;/P&gt;&lt;/FONT&gt;&lt;/STRONG&gt;&lt;img src="http://sqlblogcasts.com/aggbug.aspx?PostID=4728" width="1" height="1"&gt;</content><author><name>sqlworkshops</name><uri>http://sqlblogcasts.com/members/sqlworkshops.aspx</uri></author></entry></feed>