diff options
author | Aleksander Machniak <alec@alec.pl> | 2013-06-08 19:53:04 +0200 |
---|---|---|
committer | Aleksander Machniak <alec@alec.pl> | 2013-06-08 19:53:04 +0200 |
commit | 66407a75d1eced92d0bd725caa028f54a3b345be (patch) | |
tree | 40815913d7fe247301e01ec85e6f8df11ca42f79 /program/lib/Roundcube/rcube_db_sqlsrv.php | |
parent | b68e2355d7dcc40de404a93b9d39add2a6e45510 (diff) |
Fix date format issues on MS SQL Server (#1488918)
Diffstat (limited to 'program/lib/Roundcube/rcube_db_sqlsrv.php')
-rw-r--r-- | program/lib/Roundcube/rcube_db_sqlsrv.php | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/program/lib/Roundcube/rcube_db_sqlsrv.php b/program/lib/Roundcube/rcube_db_sqlsrv.php index 9958dc291..88473e213 100644 --- a/program/lib/Roundcube/rcube_db_sqlsrv.php +++ b/program/lib/Roundcube/rcube_db_sqlsrv.php @@ -46,6 +46,18 @@ class rcube_db_sqlsrv extends rcube_db } /** + * Driver-specific configuration of database connection + * + * @param array $dsn DSN for DB connections + * @param PDO $dbh Connection handler + */ + protected function conn_configure($dsn, $dbh) + { + // Set date format in case of non-default language (#1488918) + $this->query("SET DATEFORMAT ymd"); + } + + /** * Return SQL function for current time and date * * @param int $interval Optional interval (in seconds) to add/subtract |