[Koha-bugs] [Bug 7802] A MySQLism is used to get the current date.
bugzilla-daemon at bugs.koha-community.org
bugzilla-daemon at bugs.koha-community.org
Mon Sep 9 10:35:29 CEST 2013
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=7802
--- Comment #16 from Jonathan Druart <jonathan.druart at biblibre.com> ---
(In reply to Katrin Fischer from comment #15)
> Do we have a reference about CURRENT_DATE being a mysqlism?
> I found it here: http://www.contrib.andrew.cmu.edu/~shadow/sql/sql1992.txt
At least, it does not work with PostgreSQL:
postgres=# select CURRENT_DATE();
ERREUR: erreur de syntaxe sur ou près de « ( »
LIGNE 1 : select CURRENT_DATE();
^
postgres=# select current_date;
date
------------
2013-09-09
> Also bit worried about changing all those statements without tests.
I don't have the time to provide unit tests for all modified routines.
But
MariaDB [koha_devstetienne]> select CURRENT_DATE();
+----------------+
| CURRENT_DATE() |
+----------------+
| 2013-09-09 |
+----------------+
1 row in set (0.00 sec)
MariaDB [koha_devstetienne]> SELECT CAST(now() AS date);
+---------------------+
| CAST(now() AS date) |
+---------------------+
| 2013-09-09 |
+---------------------+
1 row in set (0.00 sec)
--
You are receiving this mail because:
You are watching all bug changes.
More information about the Koha-bugs
mailing list