﻿<?xml version='1.0' encoding='UTF-8'?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>SQLServerCentral / SQL Server 2005 / SQL Server 2005 Performance Tuning  / Need high resource expensive sql queries / Latest Posts</title><generator>InstantForum.NET v2.9.0</generator><description>SQLServerCentral</description><link>http://www.sqlservercentral.com/Forums/</link><webMaster>notifications@sqlservercentral.com</webMaster><lastBuildDate>Mon, 17 Jun 2013 23:41:12 GMT</lastBuildDate><ttl>20</ttl><item><title>RE: Need high resource expensive sql queries</title><link>http://www.sqlservercentral.com/Forums/Topic981376-360-1.aspx</link><description>[quote][b]Madhivanan-208264 (9/8/2010)[/b][hr]The avatar you used is very goodAre you a designer too? :-)[/quote]No... someone else did most of the work.  I just overlaid the word "RBAR" and converted it to a GIF.</description><pubDate>Wed, 08 Sep 2010 05:17:25 GMT</pubDate><dc:creator>Jeff Moden</dc:creator></item><item><title>RE: Need high resource expensive sql queries</title><link>http://www.sqlservercentral.com/Forums/Topic981376-360-1.aspx</link><description>[quote][b]Jeff Moden (9/7/2010)[/b][hr][quote][b]Madhivanan-208264 (9/7/2010)[/b][hr]Have a million row table and do running total using a triangular join[code="plain"]select col,(select sum(col) from table as t1 where t1.pkcol&amp;lt;=t2.pkcol) as run_sumfrom table as t2[/code][/quote]Heh... ya beat me to it, Madhivanan.[/quote]Yes. Thats the good example that I know which takes lot of time.The avatar you used is very goodAre you a designer too? :-)</description><pubDate>Wed, 08 Sep 2010 01:23:05 GMT</pubDate><dc:creator>Madhivanan-208264</dc:creator></item><item><title>RE: Need high resource expensive sql queries</title><link>http://www.sqlservercentral.com/Forums/Topic981376-360-1.aspx</link><description>Also force maxdop to 0 if your server isn't already set to it....a horrible, awful query like that should eat up every available core.</description><pubDate>Tue, 07 Sep 2010 15:35:30 GMT</pubDate><dc:creator>Derrick Smith</dc:creator></item><item><title>RE: Need high resource expensive sql queries</title><link>http://www.sqlservercentral.com/Forums/Topic981376-360-1.aspx</link><description>[quote][b]Madhivanan-208264 (9/7/2010)[/b][hr]Have a million row table and do running total using a triangular join[code="plain"]select col,(select sum(col) from table as t1 where t1.pkcol&amp;lt;=t2.pkcol) as run_sumfrom table as t2[/code][/quote]Heh... ya beat me to it, Madhivanan.</description><pubDate>Tue, 07 Sep 2010 15:20:29 GMT</pubDate><dc:creator>Jeff Moden</dc:creator></item><item><title>RE: Need high resource expensive sql queries</title><link>http://www.sqlservercentral.com/Forums/Topic981376-360-1.aspx</link><description>Have a million row table and do running total using a triangular join[code="plain"]select col,(select sum(col) from table as t1 where t1.pkcol&amp;lt;=t2.pkcol) as run_sumfrom table as t2[/code]</description><pubDate>Tue, 07 Sep 2010 06:45:30 GMT</pubDate><dc:creator>Madhivanan-208264</dc:creator></item><item><title>RE: Need high resource expensive sql queries</title><link>http://www.sqlservercentral.com/Forums/Topic981376-360-1.aspx</link><description>Errrmmm... that's a requirement not seen very often... ;-)One option would be to create a c.u.r.s.o.r. on a rather large table (to "avoid" a set based operation).Inside the c.u.r.s.o.r.:Join a large number of (large) tables on predicates that are not supported by any index (to force a table scan). Take as many columns as you like and build a large comma delimited string. Insert results into a table variable and use a loop to split the string again by stepping through each character.Most important: make sure not to run it on a production system!</description><pubDate>Tue, 07 Sep 2010 02:48:44 GMT</pubDate><dc:creator>LutzM</dc:creator></item><item><title>Need high resource expensive sql queries</title><link>http://www.sqlservercentral.com/Forums/Topic981376-360-1.aspx</link><description>Hi All,I need sql queries or bad tsql code for producing high expensive resource utilization queries to test some performance reports. I ahve adventure works database in my environment. Please let me know as from where will I get high expensive queries for my testing..thanks in advance.</description><pubDate>Tue, 07 Sep 2010 01:30:06 GMT</pubDate><dc:creator>sejal p gudhka</dc:creator></item></channel></rss>