<?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>profiling &#8211; Database Research &amp; Development</title>
	<atom:link href="https://www.dbrnd.com/tag/profiling/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.dbrnd.com</link>
	<description>BIGData &#124; NoSQL &#124; MSSQL &#124; MySQL &#124; PostgreSQL</description>
	<lastBuildDate>Sun, 31 Jul 2016 20:02:30 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=7.0.6</generator>
	<item>
		<title>MySQL: Using SQL Query Profiler finds total execution time and CPU information of the Queries</title>
		<link>https://www.dbrnd.com/2016/07/mysql-using-sql-query-profiler-finds-total-execution-time-and-cpu-information-of-the-queries/</link>
					<comments>https://www.dbrnd.com/2016/07/mysql-using-sql-query-profiler-finds-total-execution-time-and-cpu-information-of-the-queries/#comments</comments>
		
		<dc:creator><![CDATA[Anvesh Patel]]></dc:creator>
		<pubDate>Sat, 30 Jul 2016 19:59:04 +0000</pubDate>
				<category><![CDATA[MySQL]]></category>
		<category><![CDATA[MySQL DBA Script]]></category>
		<category><![CDATA[Anvesh Patel]]></category>
		<category><![CDATA[database]]></category>
		<category><![CDATA[database research and development]]></category>
		<category><![CDATA[dbrnd]]></category>
		<category><![CDATA[MySQL Command]]></category>
		<category><![CDATA[MySQL Database Administrator]]></category>
		<category><![CDATA[MySQL Database Designing]]></category>
		<category><![CDATA[MySQL Database Programming]]></category>
		<category><![CDATA[MySQL Error]]></category>
		<category><![CDATA[MySQL Performance Tunning]]></category>
		<category><![CDATA[MySQL Query]]></category>
		<category><![CDATA[MySQL Tips and Tricks]]></category>
		<category><![CDATA[profiling]]></category>
		<category><![CDATA[SHOW PROFILES]]></category>
		<category><![CDATA[SQL Profiler]]></category>
		<guid isPermaLink="false">https://www.dbrnd.com/?p=2153</guid>

					<description><![CDATA[Microsoft SQL Server Profiler is one of the important tool which is useful to find different events and statues of the running queries on Microsoft SQL Server. Do we have anything like SQL Profiler in MySQL? I have found this question on many forums and many of MySQL professionals are curious about SQL Profiler in [&#8230;]]]></description>
										<content:encoded><![CDATA[<p><a class="a2a_button_facebook" href="https://www.addtoany.com/add_to/facebook?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2016%2F07%2Fmysql-using-sql-query-profiler-finds-total-execution-time-and-cpu-information-of-the-queries%2F&amp;linkname=MySQL%3A%20Using%20SQL%20Query%20Profiler%20finds%20total%20execution%20time%20and%20CPU%20information%20of%20the%20Queries" title="Facebook" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_twitter" href="https://www.addtoany.com/add_to/twitter?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2016%2F07%2Fmysql-using-sql-query-profiler-finds-total-execution-time-and-cpu-information-of-the-queries%2F&amp;linkname=MySQL%3A%20Using%20SQL%20Query%20Profiler%20finds%20total%20execution%20time%20and%20CPU%20information%20of%20the%20Queries" title="Twitter" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_linkedin" href="https://www.addtoany.com/add_to/linkedin?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2016%2F07%2Fmysql-using-sql-query-profiler-finds-total-execution-time-and-cpu-information-of-the-queries%2F&amp;linkname=MySQL%3A%20Using%20SQL%20Query%20Profiler%20finds%20total%20execution%20time%20and%20CPU%20information%20of%20the%20Queries" title="LinkedIn" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_pinterest" href="https://www.addtoany.com/add_to/pinterest?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2016%2F07%2Fmysql-using-sql-query-profiler-finds-total-execution-time-and-cpu-information-of-the-queries%2F&amp;linkname=MySQL%3A%20Using%20SQL%20Query%20Profiler%20finds%20total%20execution%20time%20and%20CPU%20information%20of%20the%20Queries" title="Pinterest" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_reddit" href="https://www.addtoany.com/add_to/reddit?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2016%2F07%2Fmysql-using-sql-query-profiler-finds-total-execution-time-and-cpu-information-of-the-queries%2F&amp;linkname=MySQL%3A%20Using%20SQL%20Query%20Profiler%20finds%20total%20execution%20time%20and%20CPU%20information%20of%20the%20Queries" title="Reddit" rel="nofollow noopener" target="_blank"></a><a class="a2a_button_pocket" href="https://www.addtoany.com/add_to/pocket?linkurl=https%3A%2F%2Fwww.dbrnd.com%2F2016%2F07%2Fmysql-using-sql-query-profiler-finds-total-execution-time-and-cpu-information-of-the-queries%2F&amp;linkname=MySQL%3A%20Using%20SQL%20Query%20Profiler%20finds%20total%20execution%20time%20and%20CPU%20information%20of%20the%20Queries" title="Pocket" rel="nofollow noopener" target="_blank"></a><a class="a2a_dd addtoany_share_save addtoany_share" href="https://www.addtoany.com/share#url=https%3A%2F%2Fwww.dbrnd.com%2F2016%2F07%2Fmysql-using-sql-query-profiler-finds-total-execution-time-and-cpu-information-of-the-queries%2F&#038;title=MySQL%3A%20Using%20SQL%20Query%20Profiler%20finds%20total%20execution%20time%20and%20CPU%20information%20of%20the%20Queries" data-a2a-url="https://www.dbrnd.com/2016/07/mysql-using-sql-query-profiler-finds-total-execution-time-and-cpu-information-of-the-queries/" data-a2a-title="MySQL: Using SQL Query Profiler finds total execution time and CPU information of the Queries"></a></p><p><em>Microsoft SQL Server Profiler is one of the important tool which is useful to find different events and statues of the running queries on Microsoft SQL Server.</em></p>
<blockquote><p><strong>Do we have anything like SQL Profiler in MySQL?</strong></p>
<p>I have found this question on many forums and many of MySQL professionals are curious about SQL Profiler in MySQL.</p></blockquote>
<blockquote><p>MySQL has SQL Profiler which is built into the database server and you can enable/disable via the MySQL client utility.</p></blockquote>
<blockquote><p>Before executing any queries you can enable SQL Profiler and it is only for your particular session.<br />
Internally, it creates one profiling table into INFORMATION_SCHEMA database and when you disconnect with MySQL client, it destroys this table.</p></blockquote>
<p><strong>Enable SQL Profile at session level:</strong></p><pre class="crayon-plain-tag">SET profiling=1;</pre><p>
<strong>Execute sample query:</strong></p><pre class="crayon-plain-tag">SELECT *FROM table_one;
SELECT *FROM table_two;</pre><p>
<strong>Check the execution time for each query:</strong></p><pre class="crayon-plain-tag">SHOW PROFILES;

/*Result*/
Query_ID   Duration    Query
--------------------------------------------------
1          0.00355325  SELECT *FROM table_one
2          0.00051850  SELECT *FROM table_two</pre><p>
<strong>Check the execution time for second query only:</strong></p><pre class="crayon-plain-tag">SHOW PROFILE FOR QUERY 2;</pre><p>
<strong>Check the CPU information for second query only:</strong></p><pre class="crayon-plain-tag">SHOW PROFILE CPU FOR QUERY 2;</pre><p>
<strong>The Result:</strong></p>
<p><a href="https://www.dbrnd.com/wp-content/uploads/2016/03/MySQLCPUSQLProfiler.png" rel="attachment wp-att-2160"><img fetchpriority="high" decoding="async" class="alignnone wp-image-2160 size-full" title="MySQL CPU SQL Profiler" src="https://www.dbrnd.com/wp-content/uploads/2016/03/MySQLCPUSQLProfiler.png" alt="MySQL CPU SQL Profiler" width="316" height="350" srcset="https://www.dbrnd.com/wp-content/uploads/2016/03/MySQLCPUSQLProfiler.png 316w, https://www.dbrnd.com/wp-content/uploads/2016/03/MySQLCPUSQLProfiler-271x300.png 271w, https://www.dbrnd.com/wp-content/uploads/2016/03/MySQLCPUSQLProfiler-150x166.png 150w" sizes="(max-width: 316px) 100vw, 316px" /></a></p>
]]></content:encoded>
					
					<wfw:commentRss>https://www.dbrnd.com/2016/07/mysql-using-sql-query-profiler-finds-total-execution-time-and-cpu-information-of-the-queries/feed/</wfw:commentRss>
			<slash:comments>3</slash:comments>
		
		
			</item>
	</channel>
</rss>
