after nextcloud update 19.0.1 i have error: Missing index “properties_path_index” in table “oc_properties”.
If i sudo ae php occ db:add-missing-indices then i get error: PHP Parse error: syntax error, unexpected ‘class’ (T_CLASS), expecting identifier (T_STRING) or variable (T_VARIABLE) or ‘{’ or ‘$’ in /media/aecloud/nextcloud/console.php on line 97
Hi,
after nextcloud update 19.0.3 * The database is missing some indexes. Due to the fact that adding indexes on big tables could take some time they were not added automatically. By running “occ db:add-missing-indices” those missing indexes could be added manually while the instance keeps running. Once the indexes are added queries to those tables are usually much faster.
Missing index “properties_path_index” in table “oc_properties”.
The database is missing some optional columns. Due to the fact that adding columns on big tables could take some time they were not added automatically when they can be optional. By running “occ db:add-missing-columns” those missing columns could be added manually while the instance keeps running. Once the columns are added some features might improve responsiveness or usability.
Missing optional column “reference_id” in table “oc_comments”.
In case you’re on shared hosting maybe the follow SQL statements will help you to fix the problem:
ALTER TABLE `oc_properties` ADD INDEX `properties_path_index` (`userid`, `propertypath`) USING BTREE;
ALTER TABLE `oc_comments` ADD `reference_id` VARCHAR(64) NULL DEFAULT NULL;
ALTER TABLE `oc_filecache_extended` MODIFY `fileid` BIGINT(20) UNSIGNED NOT NULL;