Simple Machines Community Forum

SMF Support => SMF 2.1.x Support => Topic started by: Fassbier on April 21, 2024, 08:39:41 AM

Title: Database Error: Field 'undeletable' doesn't have a default value
Post by: Fassbier on April 21, 2024, 08:39:41 AM
Hi there,

I already fixed the problem which I could find here multiple times, to add NULL in phymyadmin in smf_message to create new topics.

Now I`m stuck with ne personal message. Here I got the error like in the Subject. I added also here the "NULL" as Standard for "undeleteable" in "smf_personal_messages" but it didn`t fix the problem.
Any advice? any other with the same problem?


Databaseerror
Field 'undeletable' doesn't have a default value
Datei: /home/xxxx/smf/Sources/Subs-Post.php
Zeile: 1186



kind regards,
Fassbier


edit: just updated from 2.0 to 2.1, if helpful
Title: Re: Database Error: Field 'undeletable' doesn't have a default value
Post by: Kindred on April 21, 2024, 08:49:32 AM
If you are still getting that exact message, then whatever change you think that you made either was tob the wrong location or did not successfully complete

There is no other fix,  other tab to remove the field entirely
Title: Re: Database Error: Field 'undeletable' doesn't have a default value
Post by: Doug Heffernan on April 21, 2024, 09:21:44 AM
That field must have come from a custom mod as there is no such field in the smf_personal_messages table. If you still are using the mod that has added, uninstall it first and then remove said field from that table.
Title: Re: Database Error: Field 'undeletable' doesn't have a default value
Post by: mickjav on April 21, 2024, 09:30:29 AM
If the data type for field in int I would use a default of 0
Title: Re: Database Error: Field 'undeletable' doesn't have a default value
Post by: Fassbier on April 22, 2024, 01:58:56 AM
Thank you all for your answers.

I`d try to delete the field "undeleteable", same message if I want to send a PM.
I`d try to change to INT and 0, same.

Maybe there is a other table in service like smf_personal_messages? I`m pretty sure that I edit the right one.

kind regards,
Fassbier
Title: Re: Database Error: Field 'undeletable' doesn't have a default value
Post by: Fassbier on April 22, 2024, 02:04:38 AM
got it, it is smf_pm_recipients.

I`m just a bit confused, there are just 2 mods installed and they have nothing to do with pm. wonder why undeletable is still there. I`ll find a way to tidy up.

thank you all!
kind regards,
Fassbier
Title: Re: Database Error: Field 'undeletable' doesn't have a default value
Post by: @rjen on April 22, 2024, 05:04:54 AM
Mods usually do not remove fields from tables upon uninstalling. So you may have had a mod in the past that you uninstalled, that left the extra fields in the table.