"Failed to count bookmarks" error messages pop up when viewing the bookmarks page
Every time I open the bookmarks application within my Nextcloud environment, I see one or multiple (I estimate the amount to be in a range from 1 till 5) pop-ups show up containing the text "Failed to count bookmarks". There still is a correct count of bookmarks in the sidebar.
To Reproduce
Steps to reproduce the behavior:
/index.php/apps/bookmarks/)Expected behavior
I do not expect any error messages to pop-up.
Screenshot

Desktop (please complete the following information):
Server:
I am running Nextcloud on my shared hosting, which is running CloudLinux.
- Nextcloud configuration:
```php
{
"system": {
"instanceid": "***REMOVED SENSITIVE VALUE***",
"passwordsalt": "***REMOVED SENSITIVE VALUE***",
"secret": "***REMOVED SENSITIVE VALUE***",
"trusted_domains": [
"tvanwoudenberg.nl",
"www.tvanwoudenberg.nl"
],
"datadirectory": "***REMOVED SENSITIVE VALUE***",
"dbtype": "mysql",
"version": "20.0.5.2",
"overwrite.cli.url": "https:\/\/tvanwoudenberg.nl\/nextcloud",
"dbname": "***REMOVED SENSITIVE VALUE***",
"dbhost": "***REMOVED SENSITIVE VALUE***",
"dbport": "",
"dbtableprefix": "oc_",
"mysql.utf8mb4": true,
"dbuser": "***REMOVED SENSITIVE VALUE***",
"dbpassword": "***REMOVED SENSITIVE VALUE***",
"installed": true,
"mail_smtpmode": "sendmail",
"mail_sendmailmode": "pipe",
"mail_from_address": "***REMOVED SENSITIVE VALUE***",
"mail_domain": "***REMOVED SENSITIVE VALUE***",
"mail_smtphost": "***REMOVED SENSITIVE VALUE***",
"mail_smtpport": "465",
"mail_smtpauthtype": "LOGIN",
"memcache.local": "\\OC\\Memcache\\APCu",
"maintenance": false
}
}
Logs
There are no Nextcloud logs for this application.
Have same error for quite some time.
As additional info I can't edit bookmarks from web ui, only add. I can edit them via android app.
Hello,
I'm sorry for the delay and for your troubles.
Can you please check the javascript logs in the browser to see what fails?
Not sure what to paste here. Full text log from console?
If I open "all bookmarks" I see a lot of errors starting from like:
TypeError: this.$refs.input is undefined bookmarks-main.js:7:11622
and later bunch of
XHR GET https://owncloud.xxxx.xxx/index.php/apps/bookmarks/folder/2/count
[HTTP/1.1 500 Internal Server Error 0ms]
XHR GEThttps://owncloud.xxxx.xxx/index.php/apps/bookmarks/folder/2/publictoken
[HTTP/1.1 500 Internal Server Error 0ms]
Error: Request failed with status code 500 bookmarks-main.js:1:7878
When I try to edit I got few
XHR PUThttps://owncloud.xxxx.xxx/index.php/apps/bookmarks/bookmark/201
[HTTP/1.1 500 Internal Server Error 0ms]
Error: Request failed with status code 500 bookmarks-main.js:1:9773
That's a good start. Thank you.
That means there should be some error logs in the nextcloud log on the server. Can you check?
I can check for sure.
I see no errors in Apache error log (ErrorLog directive in config) , only access/requests.
This is error in Nextcloud log.
List parent folder produce bunch errors like this (manually formatted):
Apr 04 11:41:36 [Nextcloud] {"reqId":"YGl7wMVQoRoP1lVq9caVLAAAAIE","level":3,"time":"2021-04-04T08:41:36+00:00","remoteAddr":"192.168.0.51","user":"evadim","app":"index","method":"GET","url":"/index.php/apps/bookmarks/folder/3/shares","message":"
{\"Exception\":\"BadFunctionCallException\",\"Message\":\"parentFolder is not a valid attribute\",\"Code\":0,\"Trace\":
[{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/public/AppFramework/Db/Entity.php\",\"line\":151,\"function\":\"setter\",\"class\":\"OCP\\\\AppFramework\\\\Db\\\\Entity\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/public/AppFramework/Db/Entity.php\",\"line\":73,\"function\":\"__call\",\"class\":\"OCP\\\\AppFramework\\\\Db\\\\Entity\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/public/AppFramework/Db/QBMapper.php\",\"line\":307,\"function\":\"fromRow\",\"class\":\"OCP\\\\AppFramework\\\\Db\\\\Entity\",\"type\":\"::\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/public/AppFramework/Db/QBMapper.php\",\"line\":346,\"function\":\"mapRowToEntity\",\"class\":\"OCP\\\\AppFramework\\\\Db\\\\QBMapper\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/apps/bookmarks/lib/Db/FolderMapper.php\",\"line\":75,\"function\":\"findEntity\",\"class\":\"OCP\\\\AppFramework\\\\Db\\\\QBMapper\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/apps/bookmarks/lib/Service/Authorizer.php\",\"line\":262,\"function\":\"find\",\"class\":\"OCA\\\\Bookmarks\\\\Db\\\\FolderMapper\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/apps/bookmarks/lib/Service/Authorizer.php\",\"line\":143,\"function\":\"getUserPermissionsForFolder\",\"class\":\"OCA\\\\Bookmarks\\\\Service\\\\Authorizer\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/apps/bookmarks/lib/Controller/FoldersController.php\",\"line\":575,\"function\":\"getPermissionsForFolder\",\"class\":\"OCA\\\\Bookmarks\\\\Service\\\\Authorizer\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/apps/bookmarks/lib/Controller/InternalFoldersController.php\",\"line\":163,\"function\":\"getShares\",\"class\":\"OCA\\\\Bookmarks\\\\Controller\\\\FoldersController\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/private/AppFramework/Http/Dispatcher.php\",\"line\":218,\"function\":\"getShares\",\"class\":\"OCA\\\\Bookmarks\\\\Controller\\\\InternalFoldersController\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/private/AppFramework/Http/Dispatcher.php\",\"line\":127,\"function\":\"executeController\",\"class\":\"OC\\\\AppFramework\\\\Http\\\\Dispatcher\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/private/AppFramework/App.php\",\"line\":157,\"function\":\"dispatch\",\"class\":\"OC\\\\AppFramework\\\\Http\\\\Dispatcher\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/private/Route/Router.php\",\"line\":302,\"function\":\"main\",\"class\":\"OC\\\\AppFramework\\\\App\",\"type\":\"::\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/base.php\",\"line\":993,\"function\":\"match\",\"class\":\"OC\\\\Route\\\\Router\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/index.php\",\"line\":37,\"function\":\"handleRequest\",\"class\":\"OC\",\"type\":\"::\"}],\"File\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/public/AppFramework/Db/Entity.php\",\"Line\":122,\"CustomMessage\":\"--
\"}","userAgent":"Mozilla/5.0 (X11; Linux x86_64; rv:87.0) Gecko/20100101 Firefox/87.0","version":"21.0.0.18"}
edit bookmark
Apr 04 11:32:11 [Nextcloud] {"reqId":"YGl5ixB0sFPPG@wknrOwUwAAAEw","level":3,"time":"2021-04-04T08:32:11+00:00","remoteAddr":"192.168.0.51","user":"evadim","app":"index","method":"PUT","url":"/index.php/apps/bookmarks/bookmark/201","message":"
{\"Exception\":\"BadFunctionCallException\",\"Message\":\"parentFolder is not a valid attribute\",\"Code\":0,\"Trace\":
[{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/public/AppFramework/Db/Entity.php\",\"line\":151,\"function\":\"setter\",\"class\":\"OCP\\\\AppFramework\\\\Db\\\\Entity\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/public/AppFramework/Db/Entity.php\",\"line\":73,\"function\":\"__call\",\"class\":\"OCP\\\\AppFramework\\\\Db\\\\Entity\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/public/AppFramework/Db/QBMapper.php\",\"line\":307,\"function\":\"fromRow\",\"class\":\"OCP\\\\AppFramework\\\\Db\\\\Entity\",\"type\":\"::\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/public/AppFramework/Db/QBMapper.php\",\"line\":346,\"function\":\"mapRowToEntity\",\"class\":\"OCP\\\\AppFramework\\\\Db\\\\QBMapper\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/apps/bookmarks/lib/Db/FolderMapper.php\",\"line\":75,\"function\":\"findEntity\",\"class\":\"OCP\\\\AppFramework\\\\Db\\\\QBMapper\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/apps/bookmarks/lib/Service/Authorizer.php\",\"line\":262,\"function\":\"find\",\"class\":\"OCA\\\\Bookmarks\\\\Db\\\\FolderMapper\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/apps/bookmarks/lib/Service/Authorizer.php\",\"line\":143,\"function\":\"getUserPermissionsForFolder\",\"class\":\"OCA\\\\Bookmarks\\\\Service\\\\Authorizer\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/apps/bookmarks/lib/Controller/BookmarkController.php\",\"line\":443,\"function\":\"getPermissionsForFolder\",\"class\":\"OCA\\\\Bookmarks\\\\Service\\\\Authorizer\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/apps/bookmarks/lib/Controller/InternalBookmarkController.php\",\"line\":116,\"function\":\"editBookmark\",\"class\":\"OCA\\\\Bookmarks\\\\Controller\\\\BookmarkController\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/private/AppFramework/Http/Dispatcher.php\",\"line\":218,\"function\":\"editBookmark\",\"class\":\"OCA\\\\Bookmarks\\\\Controller\\\\InternalBookmarkController\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/private/AppFramework/Http/Dispatcher.php\",\"line\":127,\"function\":\"executeController\",\"class\":\"OC\\\\AppFramework\\\\Http\\\\Dispatcher\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/private/AppFramework/App.php\",\"line\":157,\"function\":\"dispatch\",\"class\":\"OC\\\\AppFramework\\\\Http\\\\Dispatcher\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/private/Route/Router.php\",\"line\":302,\"function\":\"main\",\"class\":\"OC\\\\AppFramework\\\\App\",\"type\":\"::\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/base.php\",\"line\":993,\"function\":\"match\",\"class\":\"OC\\\\Route\\\\Router\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/index.php\",\"line\":37,\"function\":\"handleRequest\",\"class\":\"OC\",\"type\":\"::\"}],\"File\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/public/AppFramework/Db/Entity.php\",\"Line\":122,\"CustomMessage\":\"--
\"}","userAgent":"Mozilla/5.0 (X11; Linux x86_64; rv:87.0) Gecko/20100101 Firefox/87.0","version":"21.0.0.18"}
Where I can find more?
Also, may be related error (seen later on):
Apr 04 11:59:02 [Nextcloud] {"reqId":"YGl-1cVQoRoP1lVq9caVtwAAAIw","level":3,"time":"2021-04-04T08:59:02+00:00","remoteAddr":"192.168.0.51","user":"evadim","app":"PHP","method":"POST","url":"/index.php/settings/apps/enable","message":"
{\"Exception\":\"Error\",\"Message\":\"Undefined index: workflowengine at /var/www/owncloud.xxxx.xxx/htdocs/lib/private/AppFramework/Bootstrap/RegistrationContext.php#404\",\"Code\":0,\"Trace\":
[{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/private/AppFramework/Bootstrap/RegistrationContext.php\",\"line\":404,\"function\":\"onError\",\"class\":\"OC\\\\Log\\\\ErrorHandler\",\"type\":\"::\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/private/AppFramework/Bootstrap/Coordinator.php\",\"line\":143,\"function\":\"delegateContainerRegistrations\",\"class\":\"OC\\\\AppFramework\\\\Bootstrap\\\\RegistrationContext\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/private/AppFramework/Bootstrap/Coordinator.php\",\"line\":86,\"function\":\"registerApps\",\"class\":\"OC\\\\AppFramework\\\\Bootstrap\\\\Coordinator\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/private/Installer.php\",\"line\":146,\"function\":\"runLazyRegistration\",\"class\":\"OC\\\\AppFramework\\\\Bootstrap\\\\Coordinator\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/apps/settings/lib/Controller/AppSettingsController.php\",\"line\":448,\"function\":\"installApp\",\"class\":\"OC\\\\Installer\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/private/AppFramework/Http/Dispatcher.php\",\"line\":218,\"function\":\"enableApps\",\"class\":\"OCA\\\\Settings\\\\Controller\\\\AppSettingsController\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/private/AppFramework/Http/Dispatcher.php\",\"line\":127,\"function\":\"executeController\",\"class\":\"OC\\\\AppFramework\\\\Http\\\\Dispatcher\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/private/AppFramework/App.php\",\"line\":157,\"function\":\"dispatch\",\"class\":\"OC\\\\AppFramework\\\\Http\\\\Dispatcher\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/private/Route/Router.php\",\"line\":302,\"function\":\"main\",\"class\":\"OC\\\\AppFramework\\\\App\",\"type\":\"::\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/base.php\",\"line\":993,\"function\":\"match\",\"class\":\"OC\\\\Route\\\\Router\",\"type\":\"->\"},
{\"file\":\"/var/www/owncloud.xxxx.xxx/htdocs/index.php\",\"line\":37,\"function\":\"handleRequest\",\"class\":\"OC\",\"type\":\"::\"}],\"File\":\"/var/www/owncloud.xxxx.xxx/htdocs/lib/private/Log/ErrorHandler.php\",\"Line\":92,\"CustomMessage\":\"--
\"}","userAgent":"Mozilla/5.0 (X11; Linux x86_64; rv:87.0) Gecko/20100101 Firefox/87.0","version":"21.0.0.18"}
huh. It looks like one of your SQL tables has not been migrated correctly.
bookmarks_folders should not contain a parent_folder column. Can you run the following in your MariaDB console?
DESCRIBE oc_bookmarks;
DESCRIBE oc_bookmarks_folders;
DESCRIBE oc_bookmarks_tree;
SELECT * from oc_migrations where app = 'bookmarks';
These will output the current configuration of some of the tables of the bookmarks app, and the last query will output the current theoretical state of your database migrations concerning the bookmarks app.
Sure, here you are:
MariaDB [owncloud]> DESCRIBE oc_bookmarks;
+---------------+------------------+------+-----+---------+----------------+
| Field | Type | Null | Key | Default | Extra |
+---------------+------------------+------+-----+---------+----------------+
| id | int(11) | NO | PRI | NULL | auto_increment |
| url | varchar(4096) | NO | | | |
| title | varchar(4096) | NO | | | |
| user_id | varchar(64) | NO | MUL | | |
| description | varchar(4096) | NO | | | |
| public | smallint(6) | YES | | 0 | |
| added | int(10) unsigned | YES | | 0 | |
| lastmodified | int(10) unsigned | YES | | 0 | |
| clickcount | int(10) unsigned | NO | | 0 | |
| last_preview | int(10) unsigned | YES | MUL | 0 | |
| available | tinyint(1) | NO | MUL | 1 | |
| archived_file | bigint(20) | YES | | NULL | |
+---------------+------------------+------+-----+---------+----------------+
12 rows in set (0.004 sec)
MariaDB [owncloud]> DESCRIBE oc_bookmarks_folders;
+---------------+---------------+------+-----+---------+----------------+
| Field | Type | Null | Key | Default | Extra |
+---------------+---------------+------+-----+---------+----------------+
| id | bigint(20) | NO | PRI | NULL | auto_increment |
| parent_folder | bigint(20) | YES | | NULL | |
| title | varchar(4096) | NO | | | |
| user_id | varchar(64) | NO | MUL | | |
| index | bigint(20) | NO | | 0 | |
+---------------+---------------+------+-----+---------+----------------+
5 rows in set (0.001 sec)
MariaDB [owncloud]> DESCRIBE oc_bookmarks_tree;
+---------------+---------------------+------+-----+---------+-------+
| Field | Type | Null | Key | Default | Extra |
+---------------+---------------------+------+-----+---------+-------+
| type | varchar(20) | NO | PRI | NULL | |
| id | bigint(20) | NO | PRI | NULL | |
| parent_folder | bigint(20) | NO | PRI | NULL | |
| index | bigint(20) unsigned | NO | | NULL | |
+---------------+---------------------+------+-----+---------+-------+
4 rows in set (0.001 sec)
MariaDB [owncloud]> SELECT * from oc_migrations where app = 'bookmarks';
+-----------+-----------------------------+
| app | version |
+-----------+-----------------------------+
| bookmarks | 000014000Date20181002094721 |
| bookmarks | 000014000Date20181029094721 |
| bookmarks | 000016005Date20190402094721 |
| bookmarks | 001000007Date20190721094721 |
| bookmarks | 003000000Date20191123094721 |
| bookmarks | 003000000Date20191129094721 |
| bookmarks | 003000009Date20200505094721 |
| bookmarks | 003001000Date20200526094721 |
| bookmarks | 003001000Date20200526124721 |
| bookmarks | 003004000Date20200807124721 |
| bookmarks | 003004000Date20200817124721 |
+-----------+-----------------------------+
11 rows in set (0.000 sec)
It looks like you're missing migration 003000000Date20191129094721, even though the migrations table says it was run.
Migration 003000000Date20191129094721 does the following:
$schema->dropTable('bookmarks_folders_bookmarks');
$table = $schema->getTable('bookmarks');
$table->addIndex(['lastmodified'], 'bookmarks_modified');
$table = $schema->getTable('bookmarks_folders');
$table->dropColumn('parent_folder');
$table->dropColumn('index');
So, steps you can take to mitigate this situation:
DROP TABLE oc_bookmarks_folders_bookmarksALTER TABLE oc_bookmarks_folders DROP COLUMN parent_folder;ALTER TABLE oc_bookmarks_folders DROP COLUMN index;CREATE INDEX bookmarks_modified ON oc_bookmarks ( lastmodified );Update: Fixed copy pasta.
Thanks a lot for you help, @marcelklehr !
If I'm right, line 2 miss semicolon at the end.
line 4 gave error:
ALTER TABLE oc_bookmarks_folders DROP COLUMN index;
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'index' at line 1
I see index in table oc_bookmarks_folders, here console output in case you can find some useful info in it. Regarding multiple errors: I retyped some symbols by hand to see if there is error, but no luck.
Database changed
MariaDB [owncloud]> DROP TABLE oc_bookmarks_folders_bookmarks;
Query OK, 0 rows affected (0.007 sec)
MariaDB [owncloud]> ALTER TABLE oc_bookmarks_folders DROP COLUMN parent_folder;
Query OK, 0 rows affected (0.034 sec)
Records: 0 Duplicates: 0 Warnings: 0
MariaDB [owncloud]> ALTER TABLE oc_bookmarks_folders DROP COLUMN index;
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'index' at line 1
MariaDB [owncloud]> ALTER TABLE oc_bookmarks_folders DROP COLUMN index;
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'index' at line 1
MariaDB [owncloud]> ALTER TABLE oc_bookmarks_folders DROP COLUMN index;
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'index' at line 1
MariaDB [owncloud]> CREATE INDEX bookmarks_modified ON oc_bookmarks ( lastmodified );
Query OK, 0 rows affected (0.024 sec)
Records: 0 Duplicates: 0 Warnings: 0
MariaDB [owncloud]> DESCRIBE oc_bookmarks_folders;
+---------+---------------+------+-----+---------+----------------+
| Field | Type | Null | Key | Default | Extra |
+---------+---------------+------+-----+---------+----------------+
| id | bigint(20) | NO | PRI | NULL | auto_increment |
| title | varchar(4096) | NO | | | |
| user_id | varchar(64) | NO | MUL | | |
| index | bigint(20) | NO | | 0 | |
+---------+---------------+------+-----+---------+----------------+
4 rows in set (0.001 sec)
As you can see, move forward to execute line 5, but I still have same errors in UI.
Ah, index is of course a reserved word in MySQL, so it should be ALTER TABLE oc_bookmarks_folders DROP COLUMN 'index';
Same thing:
MariaDB [owncloud]> ALTER TABLE oc_bookmarks_folders DROP COLUMN 'index';
ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ''index'' at line 1
Aha! Error was in quotation marks! As search show ` must be used for column names, so:
MariaDB [owncloud]> ALTER TABLE oc_bookmarks_folders DROP COLUMN `index`;
Query OK, 0 rows affected (0.032 sec)
Records: 0 Duplicates: 0 Warnings: 0
did the trick! Last line gave me duplicated error but this is expected:
MariaDB [owncloud]> CREATE INDEX bookmarks_modified ON oc_bookmarks ( lastmodified );
ERROR 1061 (42000): Duplicate key name 'bookmarks_modified'
Now I see no errors in the UI and able to edit bookmarks, thank you very much for the help!