ShaneFoster Posted August 3, 2011 Share Posted August 3, 2011 Hi, I followed the directions to upgrade at, http://processwire.com/talk/index.php?topic=58.0. Now, when I view my site I see the error: "Unable to complete this request due to an error". I turned Debug mode on. I now see: Fatal error: Exception: Unknown column 'templates.flags' in 'field list' SELECT templates.id,templates.name,templates.fieldgroups_id,templates.flags,templates.cache_time,templates.data FROM `templates` ORDER BY templates.name (in C:\new_wamp\wamp\www\pwire2\wire\core\Database.php line 72) #0 C:\new_wamp\wamp\www\pwire2\wire\core\SaveableItems.php(132): Database->query(Object(DatabaseQuerySelect)) #1 [internal function]: WireSaveableItems->___load(Object(TemplatesArray)) #2 C:\new_wamp\wamp\www\pwire2\wire\core\Wire.php(267): call_user_func_array(Array, Array) #3 C:\new_wamp\wamp\www\pwire2\wire\core\Wire.php(229): Wire->runHooks('load', Array) #4 [internal function]: Wire->__call('load', Array) #5 C:\new_wamp\wamp\www\pwire2\wire\core\Templates.php(83): Templates->load(Object(TemplatesArray)) #6 C:\new_wamp\wamp\www\pwire2\wire\core\ProcessWire.php(116): Templates->init() #7 C:\new_wamp\wamp\www\pwire2\wire\core\ProcessWire.php(45): ProcessWire->load(Object(Config)) #8 C:\new_wamp\wamp\www\pwire2\index.php(151): Proce in C:\new_wamp\wamp\www\pwire2\index.php on line 186 This error message was shown because the site is in DEBUG mode. Even with this message I can't seem to debug what's causing the issue. It occurs every time I upload the 2.1 /wire folder and overwrite my old /wire version from 2.0. I have tried multiple times, but I can't seem to avoid this error. I searched the forums. I didn't find any similar issues. This is my last attempt to figure this out. I'm at a loss right now. Thanks in advance to anyone that can provide some insight! Shane Link to comment Share on other sites More sharing options...
apeisa Posted August 3, 2011 Share Posted August 3, 2011 Welcome to the forums Shane! I think you have wrong instructions here. Updating 2.0 to 2.1 requires running upgrade.php script which comes with 2.1. Never run that script myself so not sure how it works and if it.is stable yet, but it would be great if you try it. I'm not sure but here might be topic about that also. http://processwire.com/talk/index.php/topic,338.msg2071.html#msg2071 //Adamkiss: glued together this and the next topic. Link to comment Share on other sites More sharing options...
slkwrm Posted August 3, 2011 Share Posted August 3, 2011 I've never upgraded PW, but it seems like you just don't have "flags" field in your "templates" table. If you use PHPMyAdmin try to add field manually. Go to your PW db, choose "template" table, add field (after fieldgroups_id). Enter this values: Field: flags Type: int Length/Values: 11 Default: As defined, 0 Or if you use prefer using sql statement, then connect tou your MySQL server: mysql>use yourprocesswiredatabase (replace it with your actual PW database) ALTER TABLE `templates` ADD `flags` INT( 11 ) NOT NULL DEFAULT '0' I hope this will help you to solve this problem, didn't test it though. Link to comment Share on other sites More sharing options...
ShaneFoster Posted August 3, 2011 Author Share Posted August 3, 2011 Thanks for the prompt responses, guys! I'll give your suggestions a try in a little while. I'll report back with my resolution. Thanks, again. Link to comment Share on other sites More sharing options...
Adam Kiss Posted August 3, 2011 Share Posted August 3, 2011 @Shane: Yes, welcome to forums. Switching between minor versions comes with a few pullbacks, so you have to use aforementioned upgrade.php. Hopefully, upgrading even between minor versions will be solved in future releases, though it's not currently on roadmap (although, with features in 2.2, being mostly multilanguage support, we should come up with a good solution) @Antti: I glued your posts together, you'll never learn to modify your posts, will you? @slkwrm: While helpful, I don't advise this – like many 'somewher deep in core' errors, this might bring another error, and you just may end up adding/editing multiple columns and doing other databse operation, which might not be the best solution. Link to comment Share on other sites More sharing options...
slkwrm Posted August 3, 2011 Share Posted August 3, 2011 @Adamkiss Yes, definetely it's not really good solution, didn't know anything about upgrade.php @Shane You should follow Apeisa's instructions and use upgrade.php Link to comment Share on other sites More sharing options...
apeisa Posted August 4, 2011 Share Posted August 4, 2011 Adam: Thanks for cleaning my mess. I use forums from my mobile phone quite a often and there I tend to take shortest route. This reply area somehow goes all crazy on my android. Link to comment Share on other sites More sharing options...
ryan Posted August 8, 2011 Share Posted August 8, 2011 Shane--hold off in upgrading for another week or two. There are major core changes from 2.0 to 2.1 so an upgrade script has to be involved. This upgrade script is in production and it's not quite ready. Stick with 2.0 for a little while longer. Don't do any manual table changes with PHPMyAdmin, because that's just a small part of what's changed. So in the short term, I'd recommend removing the 2.1 /wire/ dir and putting the 2.0 /wire/ dir back in place (as well as /index.php, if you replaced that too). Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now