Unable to save new sermon

More
25 Apr 2022 07:02 #7888 by Brendan
Probably me making a sillly mistake, but when I try to publish I get this

Save failed with the following error: Field 'custom1' doesn't have a default value

 Any ideas what this means please?

Please Log in or Create an account to join the conversation.

More
25 Apr 2022 17:31 #7889 by Thomas Hunziker
Yep, I know what it means (obviously a bug in SermonSpeaker) and I even know where it comes from :-)

Older SermonSpeaker versions had a feature which allowed to fill two additional database fields named custom1 and custom2. Probably only a few really used it. Since Joomla added a Custom Field feature for quite some time already, I removed that SermonSpeaker feature with version 6.0.0. So new installations don't have those field anymore while updated ones still have it, but the code doesn't support it anymore.

Now with Joomla 4, the database runs in "strict" mode. Which means it is much stricter when it comes to database query errors. And here SermonSpeaker tries to fill a sermon row but doesn't provide a value for those two fields, which is wrong.

Now there are two solutions, both need phpMyAdmin or a similar database tool. You can either set an empty value as default for the fields custom1 and custom2, or you can just delete the two fields.
I will have to do a similar thing for the update script in SermonSpeaker to take care of this automatically.

Please Log in or Create an account to join the conversation.

More
26 Apr 2022 03:41 #7890 by Brendan
Replied by Brendan on topic Unable to save new sermon
Thanks Thomas, that worked.

Just for future reference, delete tables custom1 and custom2 from *_sermon_sermons table.

Please Log in or Create an account to join the conversation.

More
26 Apr 2022 11:09 #7894 by Thomas Hunziker
With the next version, they will be deleted automatically. Just wrote the code for it.

Please Log in or Create an account to join the conversation.

Time to create page: 0.171 seconds
Powered by Kunena Forum