Architecture / Installation

Architecture / Installation

Upgraded database has different column defaults compared to clean install

posts: 3 Netherlands

I have been introduced to tikiwiki when version 15 was released.

The website I maintain has been upgraded from a MyISAM databse from tiki 15->18->21 (maybe even older versions) and I'm now in charge of migrating it to an InnoDB-based tiki 24. There were of course some expected issues with zero-dates and indexing issues with character sets and collations not matching, but nothing that wasn't fixable.

After upgrading, I did notice some bugs in our webshop/payment plugin while testing. The payment could not be entered in the database because the default value for the `status` column in the `tiki_payment_received` table was set to NULL, whereas the php code expects it to be 'paid' by default (which it is on a clean install of 24).

So I compared the default values of my migrated database to the default values of a cleanly installed tiki24 database. And I found quite a lot of differences. I was able to create a script that generates "ALTER TABLE" lines for the table column default values that do not match.

Is it okay if I manually run this MySQL script to alter all the table columns default values to match those of the freshly installed tiki 24 DB?

Or might that mess up any future upgrades with the expected values as used in the scripts that are used for each upgrade in the tiki/db folder?

Upcoming Events

1)  15 Jun 2023 14:00 GMT-0000
Tiki Roundtable Meeting - June 2023
2)  20 Jul 2023 14:00 GMT-0000
Tiki Roundtable Meeting - July