Hi,
When logging in (and during usage) of the web interface, I get the following message:
Database error
Invalid SQL: SELECT * FROM egw_notificationpopup WHERE account_id=1000 AND notify_type=‘base’ ORDER BY notify_id DESC LIMIT 0,100
ERROR: LIMIT #,# syntax is not supported
LINE 1: …00 AND notify_type=‘base’ ORDER BY notify_id DESC LIMIT 0,10…
^
HINT: Use separate LIMIT and OFFSET clauses. (-1)
I use PostgreSQL for my database.
I use “git” to update my instance.
The following DIFF resolves this issue. (No check done for database type):
diff --git a/notifications/inc/class.notifications_ajax.inc.php b/notifications/inc/class.notifications_ajax.inc.php
index 92ace80549…25a8e828a1 100644
— a/notifications/inc/class.notifications_ajax.inc.php
+++ b/notifications/inc/class.notifications_ajax.inc.php
@@ -180,7 +180,7 @@ class notifications_ajax {
‘account_id’ => $this->recipient->account_id,
‘notify_type’ => self::_type
),
-
__LINE__,__FILE__,false,'ORDER BY notify_id DESC LIMIT 0,100',self::_appname);
-
__LINE__,__FILE__,false,'ORDER BY notify_id DESC LIMIT 100 OFFSET 0',self::_appname);
$result = array();
if ($rs->NumRows() > 0) {
foreach ($rs as $notification) {