help.nextcloud.com is for home/non-enterprise users. If you’re running a business, paid support can be accessed via portal.nextcloud.com where we can ensure your business keeps running smoothly.
In order to help you as quickly as possible, before clicking Create Topic please provide as much of the below as you can. Feel free to use a pastebin service for logs, otherwise either indent short log examples with four spaces:
example
Or for longer, use three backticks above and below the code snippet:
longer
example
here
Some or all of the below information will be requested if it isn’t supplied; for fastest response please provide as much as you can
Nextcloud version (eg, 12.0.2): 16.0.6
Operating system and version (eg, Ubuntu 17.04): Centos 7
Apache or nginx version (eg, Apache 2.4.25): Apache/2.4.6
PHP version (eg, 7.1): PHP 7.2.20
The issue you are facing:
After running “occ db:add-missing-indices” it returns
Check indices of the share table.
Check indices of the filecache table.
Check indices of the twofactor_providers table.
Check indices of the login_flow_v2 table.
Check indices of the whats_new table.
Check indices of the cards table.
Check indices of the cards_properties table.
Adding cards_prop_abid index to the cards_properties table, this can take some time...
In AbstractMySQLDriver.php line 125:
An exception occurred while executing 'DROP INDEX idx_811f5cfa8b26c2e9 ON oc_cards_properties':
SQLSTATE[42000]: Syntax error or access violation: 1280 Incorrect index name 'card_value_index'
In PDOConnection.php line 109:
SQLSTATE[42000]: Syntax error or access violation: 1280 Incorrect index name 'card_value_index'
In PDOConnection.php line 107:
SQLSTATE[42000]: Syntax error or access violation: 1280 Incorrect index name 'card_value_index'
db:add-missing-indices
Is this the first time you’ve seen this error? (Y/N):
No, it was there in the 16.0.5 version as well, since it didn’t cause much trouble I waited for the next update.
I already tried to truncate the oc_cards and oc_cards_properties tables, this did not help. Any suggestions?
EDIT: In case it might be relevant, I’m trying to run “occ db:add-missing-indices”
because cards_prop_abid seems to be missing.
MariaDB [******]> DROP INDEX idx_811f5cfa8b26c2e9 ON oc_cards_properties;
Query OK, 0 rows affected (0.01 sec)
Records: 0 Duplicates: 0 Warnings: 0
After which occ db:add-missing-indices
ran with no trouble at all:
Check indices of the share table.
Check indices of the filecache table.
Check indices of the twofactor_providers table.
Check indices of the login_flow_v2 table.
Check indices of the whats_new table.
Check indices of the cards table.
Check indices of the cards_properties table.
Adding cards_prop_abid index to the cards_properties table, this can take some time...
cards_properties table updated successfully.
Thank you so much!
(also thanks for not hand feeding me a solution)
For future reference:
I also initiated a filescan afterwards with