nextcloud / cms_pico

🗃 Integrate Pico CMS and let your users manage their own websites
https://apps.nextcloud.com/apps/cms_pico
GNU Affero General Public License v3.0
134 stars 42 forks source link

How to recreate database tables? #223

Closed atkulp closed 1 year ago

atkulp commented 1 year ago

I had some issues with my installation and ended up removing everything. Now even with a full reinstall (removing the files manually), I can't get it to recreate the database tables. What can I do to get these tables back? I'm running using the Nextcloud Docker image with MariaDB.

Nextcloud 24.0.7 Pico CMS 1.0.20

{"Exception":"PDOException","Message":"SQLSTATE[42S02]: Base table or view not found: 1146 Table 'nextcloud.oc_cms_pico_websites' doesn't exist","Code":"42S02"

PhrozenByte commented 1 year ago

Please don't try deleting stuff yourself, Nextcloud provides a clean way to uninstall apps.

Remove the app, remove the oc_cms_pico_websites table and also remove all entries of cms_pico from the oc_appinfo and oc_migrations tables.

atkulp commented 1 year ago

I was trying to reinstall to reset the configuration by removing and reinstalling kept coming right back to the same configured settings. Manually deleting was definitely a bad idea in this case!

I got it to work, but I don't have an oc_appinfo table so I cleared entries from oc_appconfig with cms_pico.

Thanks for your help!