]> git.joonet.de Git - adminer.git/commitdiff
Use numeric time zone in export (thanks to Martin Dzubak)
authorJakub Vrana <jakub@vrana.cz>
Thu, 11 Apr 2013 17:12:53 +0000 (10:12 -0700)
committerJakub Vrana <jakub@vrana.cz>
Thu, 11 Apr 2013 17:12:53 +0000 (10:12 -0700)
adminer/dump.inc.php
changes.txt

index 57fe60bc1a094fba29236618eb1cb63bd426ec66..ee3f3d0ddbd8656a055e0ba80a74301ae139c19c 100644 (file)
@@ -14,7 +14,7 @@ if ($_POST) {
 
 " . ($jush != "sql" ? "" : "SET NAMES utf8;
 " . ($_POST["data_style"] ? "SET foreign_key_checks = 0;
-SET time_zone = " . q($connection->result("SELECT @@time_zone")) . ";
+SET time_zone = " . q(substr(preg_replace('~^[^-]~', '+\0', $connection->result("SELECT TIMEDIFF(NOW(), UTC_TIMESTAMP)")), 0, 6)) . ";
 SET sql_mode = 'NO_AUTO_VALUE_ON_ZERO';
 " : "") . "
 ");
index 669437cca39585dfbed6a61b4e17c011c3a23a06..ebac56738416785362621be8aef1f233a02ebe43 100644 (file)
@@ -11,6 +11,7 @@ Open database to a new window after selecting it with Ctrl
 Disable autocapitalize in identifiers on mobile browsers
 MySQL: Compatibility with MySQL 5.6
 MySQL: Move ALTER export to plugin
+MySQL: Use numeric time zone in export
 SQLite: Export indexes
 
 Adminer 3.6.3 (released 2013-01-23):