<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Joseph Piché &#187; query</title>
	<atom:link href="http://jpiche.com/tags/query/feed/" rel="self" type="application/rss+xml" />
	<link>http://jpiche.com</link>
	<description>Web development professional with expertise in PHP, MySQL query optimization, Ajax, and XHTML</description>
	<lastBuildDate>Tue, 20 Jul 2010 04:04:51 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>The Importance of EXPLAIN and SQL_NO_CACHE in Query Development</title>
		<link>http://jpiche.com/2009/10/the-importance-of-explain-and-sql_no_cache-in-query-development/</link>
		<comments>http://jpiche.com/2009/10/the-importance-of-explain-and-sql_no_cache-in-query-development/#comments</comments>
		<pubDate>Thu, 08 Oct 2009 04:17:15 +0000</pubDate>
		<dc:creator>Joseph Piché</dc:creator>
				<category><![CDATA[SQL]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[optimization]]></category>
		<category><![CDATA[query]]></category>

		<guid isPermaLink="false">http://jpiche.com/?p=299</guid>
		<description><![CDATA[On average, I guess 35% of my over time at work involves MySQL query building, optimizing and re-writing. I find it an enjoyable challenge, and recently I re-worked an existing framework for a new site which put my focus almost solely on SQL, queries, and the schema.
With a normalized database schema, SQL optimization tends to [...]]]></description>
			<content:encoded><![CDATA[<p>On average, I guess 35% of my over time at work involves MySQL query building, optimizing and re-writing. I find it an enjoyable challenge, and recently I re-worked an existing framework for a new site which put my focus almost solely on SQL, queries, and the schema.</p>
<p>With a normalized database schema, SQL optimization tends to focus on aspects outside the query, like making sure indexes get put in the currect locations. But I happen to be stuck with large and slightly-non-normalized tables. So, in order to write queries against these tables for a site that averages 30k hits per month, I need to be able to see what MySQL is doing with each query. For this I would be lost without <code><a href="http://dev.mysql.com/doc/refman/5.1/en/using-explain.html">EXPLAIN</a></code> and <code><a href="http://dev.mysql.com/doc/refman/5.1/en/query-cache-in-select.html">SQL_NO_CACHE</a></code>.</p>
<p>I don&rsquo;t like writing tutorials, and I don&#8217;t really have time. But I love linking to <a href="http://dev.mysql.com/doc/">great documentation</a>. Most of what I know about MySQL I learned from their documentation, and I encourage even experienced query writers to make sure they know the importance of testing query times with <code>SQL_NO_CACHE</code> or using a development environment with caching completely disabled. When it comes to web applications, even microseconds can hurt in the long run.</p>
]]></content:encoded>
			<wfw:commentRss>http://jpiche.com/2009/10/the-importance-of-explain-and-sql_no_cache-in-query-development/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
