<?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>UTC &#8211; Database Research &amp; Development</title>
	<atom:link href="https://www.dbrnd.com/tag/utc/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>Wed, 11 Oct 2017 09:43:47 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=7.0.4</generator>
	<item>
		<title>MySQL: SELECT UTC_TIMESTAMP and CONVERT local date time to UTC time zone</title>
		<link>https://www.dbrnd.com/2016/03/mysql-select-utc_timestamp-and-convert-local-date-time-to-utc-time-zone/</link>
					<comments>https://www.dbrnd.com/2016/03/mysql-select-utc_timestamp-and-convert-local-date-time-to-utc-time-zone/#comments</comments>
		
		<dc:creator><![CDATA[Anvesh Patel]]></dc:creator>
		<pubDate>Wed, 23 Mar 2016 21:00:20 +0000</pubDate>
				<category><![CDATA[MySQL]]></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[TIMESTAMP]]></category>
		<category><![CDATA[UTC]]></category>
		<guid isPermaLink="false">https://www.dbrnd.com/?p=2133</guid>

					<description><![CDATA[When we are working with the big distributed database system, it is very important to take care of the default database time zone. When we are selecting data from different countries, we should always work with UTC time zone because it is a World&#8217;s time standard and stand for Universal Time Coordinated. In one of [&#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%2F03%2Fmysql-select-utc_timestamp-and-convert-local-date-time-to-utc-time-zone%2F&amp;linkname=MySQL%3A%20SELECT%20UTC_TIMESTAMP%20and%20CONVERT%20local%20date%20time%20to%20UTC%20time%20zone" 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%2F03%2Fmysql-select-utc_timestamp-and-convert-local-date-time-to-utc-time-zone%2F&amp;linkname=MySQL%3A%20SELECT%20UTC_TIMESTAMP%20and%20CONVERT%20local%20date%20time%20to%20UTC%20time%20zone" 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%2F03%2Fmysql-select-utc_timestamp-and-convert-local-date-time-to-utc-time-zone%2F&amp;linkname=MySQL%3A%20SELECT%20UTC_TIMESTAMP%20and%20CONVERT%20local%20date%20time%20to%20UTC%20time%20zone" 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%2F03%2Fmysql-select-utc_timestamp-and-convert-local-date-time-to-utc-time-zone%2F&amp;linkname=MySQL%3A%20SELECT%20UTC_TIMESTAMP%20and%20CONVERT%20local%20date%20time%20to%20UTC%20time%20zone" 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%2F03%2Fmysql-select-utc_timestamp-and-convert-local-date-time-to-utc-time-zone%2F&amp;linkname=MySQL%3A%20SELECT%20UTC_TIMESTAMP%20and%20CONVERT%20local%20date%20time%20to%20UTC%20time%20zone" 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%2F03%2Fmysql-select-utc_timestamp-and-convert-local-date-time-to-utc-time-zone%2F&amp;linkname=MySQL%3A%20SELECT%20UTC_TIMESTAMP%20and%20CONVERT%20local%20date%20time%20to%20UTC%20time%20zone" 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%2F03%2Fmysql-select-utc_timestamp-and-convert-local-date-time-to-utc-time-zone%2F&#038;title=MySQL%3A%20SELECT%20UTC_TIMESTAMP%20and%20CONVERT%20local%20date%20time%20to%20UTC%20time%20zone" data-a2a-url="https://www.dbrnd.com/2016/03/mysql-select-utc_timestamp-and-convert-local-date-time-to-utc-time-zone/" data-a2a-title="MySQL: SELECT UTC_TIMESTAMP and CONVERT local date time to UTC time zone"></a></p><blockquote><p>When we are working with the big distributed database system, it is very important to take care of the default database time zone.</p>
<p>When we are selecting data from different countries, we should always work with UTC time zone because it is a World&#8217;s time standard and stand for Universal Time Coordinated.</p></blockquote>
<blockquote><p>In one of our MySQL Database Server, we have stored all Date Time-related information based on local time zone.<br />
But now, the problem is some of the users are manipulating the same server from the different country.</p>
<p>This is creating a big problem for us because we cannot identify accurate Date Time values. </p></blockquote>
<p>The solution of this problem is to convert local time zone values into UTC time zone values. </p>
<p><strong>SELECT local time:</strong></p>
<pre class="crayon-plain-tag">SELECT NOW() AS Local_DateTime;</pre> </p>
<p><strong>SELECT UTC time:</strong></p>
<pre class="crayon-plain-tag">SELECT UTC_TIMESTAMP() AS UTC_DateTime;</pre> </p>
<p><strong>Convert local time to UTC time:</strong></p>
<pre class="crayon-plain-tag">SELECT CONVERT_TZ(NOW(), @@session.time_zone, '+00:00') AS UTC_DateTime;</pre> </p>
<blockquote><p><em>My suggestion is to store all Date_Time information under UTC time zone only.</em></p></blockquote>
]]></content:encoded>
					
					<wfw:commentRss>https://www.dbrnd.com/2016/03/mysql-select-utc_timestamp-and-convert-local-date-time-to-utc-time-zone/feed/</wfw:commentRss>
			<slash:comments>1</slash:comments>
		
		
			</item>
	</channel>
</rss>
