6.0.0-beta1
7/5/25

[#7914] MDB2_Schema Error: schema validation error
Summary MDB2_Schema Error: schema validation error
Queue Horde Groupware Webmail Edition
Queue Version 1.2.2
Type Bug
State Resolved
Priority 1. Low
Owners jan (at) horde (dot) org
Requester samuel.wolf (at) wolf-maschinenbau (dot) de
Created 01/29/2009 (6001 days ago)
Due
Updated 12/19/2009 (5677 days ago)
Assigned 09/16/2009 (5771 days ago)
Resolved 12/16/2009 (5680 days ago)
Github Issue Link
Github Pull Request
Milestone 1.2.5
Patch No

History
12/19/2009 07:19:39 PM samuel (dot) wolf (at) wolf-maschinenbau (dot) de Comment #19 Reply to this comment
Update to Horde Groupware Webmail Edition 1.2.5 without the error, thank you.

12/16/2009 10:51:44 PM Jan Schneider Comment #18
State ⇒ Resolved
Milestone ⇒ 1.2.5
Reply to this comment
This will be fixed with Groupware 1.2.5.
12/16/2009 12:06:59 AM CVS Commit Comment #17 Reply to this comment
Changes have been made in CVS for this ticket:

Bump versions, even MDB2 and MDB2_Schema because this seems to fix bug #7914.
http://cvs.horde.org/diff.php/groupware/config/Attic/pear.txt?rt=horde&r1=1.26.2.8&r2=1.26.2.9&ty=u
09/21/2009 05:30:29 PM el (dot) baby (at) gmail (dot) com Comment #16 Reply to this comment
Well, that is, unless your users had actually set alarms for a future 
date and they intend for them to work... if you delete the 
horde_alarms table, you automatically deleted all your users alarms.



You can, however, modify the structure of the table before the upgrade 
in order that it completes sucessfully:



ALTER TABLE `horde_alarms` CHANGE `alarm_start` `alarm_start` DATETIME

NOT NULL DEFAULT '0000-00-00 00:00:00'



This will NOT erase the alarms since it only changes the structure of 
the table and, actually, it only changes the DEFAULT value (which is 
used for newly inserted records and doesn't affect existing records).
09/21/2009 05:14:04 PM samuel (dot) wolf (at) wolf-maschinenbau (dot) de Comment #15 Reply to this comment
same error on upgrade from version 1.2.3 to 1.2.4.



Updating database...

[ ERROR! ] Reading the existing table structure failed. Error messages:

MDB2_Schema Error: schema validation error

default value of "alarm_start" is incorrect: "" is not of type "timestamp"



=> delete horde_alarms and the update is successful without any errors.




09/16/2009 04:21:28 PM Jan Schneider Comment #14 Reply to this comment
What I don't know is how to run the setup script "step by step" so I
can relocate pear and then run
Just pick the PEAR entry in the menu of setup.php.
09/16/2009 04:16:19 PM el (dot) baby (at) gmail (dot) com Comment #13 Reply to this comment
Well,



actually, since this was a production setup which I didn't actually 
know in what state ended, I rolled everything back to 1.2.3, restored 
the database, modified the horde_alarms table like this:



ALTER TABLE `horde_alarms` CHANGE `alarm_start` `alarm_start` DATETIME 
NOT NULL DEFAULT '0000-00-00 00:00:00'



and then successfully upgraded.



I'll try to simulate the steps you propose in another directory with a 
copy of the database but I don't know when I'll have the time (I 
already took a whole morning with this).



What I don't know is how to run the setup script "step by step" so I 
can relocate pear and then run



./horde/pear/pear -c horde/pear/horde.ini upgrade mdb2_driver_mysql-beta

(it is, actually mysql 5.0).
09/16/2009 02:56:02 PM Jan Schneider Comment #12
State ⇒ Feedback
Reply to this comment
Or try the following *after* relocating pear with the setup script, 
but *before* actually doing the upgrade.



./horde/pear/pear -c horde/pear/horde.ini upgrade mdb2_schema-beta

./horde/pear/pear -c horde/pear/horde.ini upgrade mdb2_driver_mysql-beta



Replace "mysql" with your database system. Which one do you use anyway?
09/16/2009 02:50:24 PM Jan Schneider Comment #11 Reply to this comment
Someone who is actually seeing this, has to dig through the code and 
see where it is coming from.
09/16/2009 02:48:09 PM el (dot) baby (at) gmail (dot) com Comment #10 Reply to this comment
FWIW, I just got this exact problem upgrading from 1.2.3 (which comes 
from older upgrades) into 1.2.4:



Running pre-update scripts...



Writing main configuration file

Loading database module...

Updating database...

[ ERROR! ] Reading the existing table structure failed. Error messages:

MDB2_Schema Error: schema validation error

default value of "alarm_start" is incorrect: "" is not of type "timestamp"



Running post-update scripts...

Done updating Horde Groupware Webmail Edition.



I still don't have an indication if the horde_alarms table was updated 
and even if the rest of the database was correctly updated... or what 
can I do to prevent this from happening (I can restore my backup, but 
re-doing the same steps will probably lead to the same error).
09/16/2009 12:40:34 PM Jan Schneider Comment #9
State ⇒ Not A Bug
Reply to this comment
Not reproducible.
08/13/2009 09:22:22 AM Jan Schneider Comment #8 Reply to this comment
The point is, that the MDB2_Schema validator (that we ship) complains 
about the database schema (that we ship). Since both are always the 
same, no matter from which version you update, it should either 
complain for anyone using that Horde version or for no one.
08/13/2009 05:05:11 AM hostmaster (at) taunusstein (dot) net Comment #7 Reply to this comment
That was not a fresh install from 1.2.2. This 1.2.2 database was 
created with 1.0.something and got multiple updates until 1.2.2, I 
hope this history explains the situation.



I changed database structure until 1.2.3 update tool got what it 
expected so updates was successful now.



If you cannot reproduce this error it may be helpful to update 
documentation, so admin has a chance to verify database structure 
requirements.
08/12/2009 04:56:59 PM Jan Schneider Comment #6
State ⇒ Feedback
Reply to this comment
I can't reproduce this.
07/20/2009 07:54:52 AM hostmaster (at) taunusstein (dot) net Comment #5 Reply to this comment
Is there an other way to update from 1.2.2 to 1.2.3 ?
05/01/2009 09:00:34 PM Jan Schneider Milestone ⇒ 1.2.4
 
05/01/2009 06:45:18 PM samuel (dot) wolf (at) wolf-maschinenbau (dot) de Comment #4 Reply to this comment
I'm getting this error as well upgrading from 1.2.1 to 1.2.2.
Dropping horde_alarms resolved upgrade.
same error on upgrading from 1.2.2 to 1.2.3


02/05/2009 05:50:57 PM lee (at) compucrew (dot) com Comment #3 Reply to this comment
I'm getting this error as well upgrading from 1.2.1 to 1.2.2.   
Dropping horde_alarms resolved upgrade.
01/30/2009 12:12:15 AM Jan Schneider Comment #2
Assigned to Jan Schneider
State ⇒ Assigned
Milestone ⇒ 1.2.3
Reply to this comment
You got to love MDB2_Schame, eh, MDB2_Schema.
01/29/2009 07:56:56 PM samuel (dot) wolf (at) wolf-maschinenbau (dot) de Comment #1
Priority ⇒ 1. Low
State ⇒ Unconfirmed
Patch ⇒ No
Milestone ⇒
Summary ⇒ MDB2_Schema Error: schema validation error
Type ⇒ Bug
Queue ⇒ Horde Groupware Webmail Edition
Reply to this comment
----> Get the following error from upgrade 1.2.1 to 1.2.2



Type your choice: y



Running pre-update scripts...



Writing main configuration file

Loading database module...

Updating database...

[ ERROR! ] Reading the existing table structure failed. Error messages:

MDB2_Schema Error: schema validation error

default value of "alarm_start" is incorrect: "" is not of type "timestamp"



Running post-update scripts...

Done updating Horde Groupware Webmail Edition.



----> The only way to make the upgrade is deleting the horde_alarms in 
the MySQL Database.



Type your choice: y



Running pre-update scripts...



Writing main configuration file

Loading database module...

Updating database...

[   OK   ] Successfully updated the global tables.

[   OK   ] Successfully updated the tables for Mail (imp).

[   OK   ] Successfully updated the tables for Filters (ingo).

[   OK   ] Successfully updated the tables for Address Book (turba).

[   OK   ] Successfully updated the tables for Calendar (kronolith).

[   OK   ] Successfully updated the tables for Tasks (nag).

[   OK   ] Successfully updated the tables for Notes (mnemo).

Done updating tables.





Running post-update scripts...

Done updating Horde Groupware Webmail Edition.

Saved Queries