Fork me on GitHub

[SOLVED] Upgrade to zikula 1.3.0 build 2928  Bottom

  • I have a 1.2.5 install which is upgraded to 1.2.7 with some common modules like content, addressbook and news. I tried an upgrade to 1.3.0 build 2928.

    When I tried this yesterday, I came to the "upgrading modules" page but after a few seconds the throbbler stopped without further warnings/errors etc. Reloading the page showed the following error:

    Code

    "Error in DBUtil::executeSQL: SELECT z_uid AS "uid",z_uname AS "uname",z_email AS "email",z_user_regdate AS "user_regdate",z_user_viewemail AS "user_viewemail",z_user_theme AS "user_theme",z_pass AS "pass",z_storynum AS "storynum",z_ublockon AS "ublockon",z_ublock AS "ublock",z_theme AS "theme",z_counter AS "counter",z_activated AS "activated",z_lastlogin AS "lastlogin",z_validfrom AS "validfrom",z_validuntil AS "validuntil",z_hash_method AS "hash_method" FROM z_users AS tbl WHERE z_uid = '2' LIMIT 1
    SQLSTATE[42S22]: Column not found: 1054 Unknown column 'z_user_viewemail' in 'field list'
    Error in DBUtil::executeSQL: SELECT z_uid AS "
    uid",z_uname AS "uname",z_email AS "email",z_user_regdate AS "user_regdate",z_user_viewemail AS "user_viewemail",z_user_theme AS "user_theme",z_pass AS "pass",z_storynum AS "storynum",z_ublockon AS "ublockon",z_ublock AS "ublock",z_theme AS "theme",z_counter AS "counter",z_activated AS "activated",z_lastlogin AS "lastlogin",z_validfrom AS "validfrom",z_validuntil AS "validuntil",z_hash_method AS "hash_method" FROM z_users AS tbl WHERE z_uid = '2' LIMIT 1
    SQLSTATE[42S22]: Column not found: 1054 Unknown column 'z_user_viewemail' in 'field list'


    After manually adding the column, there were some more to add. After this it goes on for the table "users_temp" which doesn't exist. Should this table exist in 1.2.x ?

    Going over upgrade.php it seems like the script is looking for tables which begin with the prefix PN and wants to change them to a new prefix, but all my tables already had a prefix "z"?

    Creating a fresh install works perfectly BTW...

    gr

    Bas
  • I was just working on some upgrade stuff yesterday and today too. Drak and I made some changes (to 1.3.0) so you might want to try again.
  • bvdbos3

    Going over upgrade.php it seems like the script is looking for tables which begin with the prefix PN and wants to change them to a new prefix, but all my tables already had a prefix "z"?


    It's actually renaming the column prefixes, not the table prefixes. Please note that if and upgrade fails in the middle you have to reset your database back to the 1.2 state (drop all tables manually and rerun your SQL restore - it is not enough to rely on DROP TABLES in your SQL dump because there are some new tables being added and populated).

    If you don't already have a user_temp table in 1.2 then something is wrong with your installation. The upgrade relies on the state of your 1.2 installation being standard. As of #2933, the upgrades should be functioning ok for core (no guarantee about individual modules).

    Drak

    --
    Zikula Lead Developer
    Board Member of the Zikula Foundation
    Follow me on twitter.com/zikuladrak
  • viewmail was introduced on 1.3-dev not too much time ago.

    It sounds like you tried to upgrade the database twice, and the second time Users version was already upgraded and tried to get that non existing field. As Drak said, after a failed attempt you need to drop the database and restore the 1.2

    Do not include third party modules which upgrade path is not confirmed.
    Enable the display_errors on your PHP server to not get a BLANK SCREEN but a detailed error message.

    Thanks for testing, and if you try again, tell us the result icon_wink

    --
    - Mateo T. -
    Mis principios... son mis fines
  • Started over, checked z_users_temp does exist in my original DB, also the z_user_viewemail column does exist in my original DB. I used build 2936 now. Some remarks:
    * In my config.php my password was encoded, does this still work in 1.3.0? There's no 'encoded' option in the config.php. For now I entered the username/password in plain-text.
    * As for the default theme, wouldn't it be safer to set the default theme to one of the stock themes during installation, after this one could always upload a new theme and switch?
    * I recall the Downloads module uses pnTemp to store it's files by default. If you delete pnTemp (as per instructions) all your downloads will break. Perhaps only delete the cache-files? As pnTemp doens't exist in the new install, the installer could do this.
    * I paid attention to $ZConfig['System']['installed'] but in an upgrade, should it be set to 0 or 1, the upgradedoc isn't clear about this.

    Now the following error rises:

    Code

    Uncaught exception empty 'page' specified in your theme page configuration on file master.ini. in /home/basvdbosch/domains/archimil.nl/public_html/z/lib/Zikula/View/Theme.php line, 674
    #0 /home/basvdbosch/domains/archimil.nl/public_html/z/lib/Zikula/View/Theme.php(228): Zikula_View_Theme->load_config()
    #1 /home/basvdbosch/domains/archimil.nl/public_html/z/lib/Zikula/View/Theme.php(277): Zikula_View_Theme->__construct(Object(Zikula_ServiceManager), NULL)
    #2 /home/basvdbosch/domains/archimil.nl/public_html/z/lib/Zikula/Core.php(473): Zikula_View_Theme::getInstance()
    #3 /home/basvdbosch/domains/archimil.nl/public_html/z/upgrade.php(65): Zikula_Core->init(4095)
    #4 {main}

    I tried setting two stock themes, seabreeze and andreas08, as default in my original DB. Both with the same result. The columns are renamed though.

    Then I tried upgrading a fresh install of 1.2.7. The uname and password are encoded by default BTW (see remark above). Same result.... I also tried ZK1.3.0 builds 2926 and 2928 with the same result.

    gr

    Bas

    edited: tried different builds of zk1.3.0



    Edited by bvdbos3 on May 14, 2011 - 11:54 PM.
  • For the theme, I had asked drak about that as well. I personally switched my theme to Andreas08 before doing a dump of my DB to test the upgrade to solve that and it worjs for me, but that won't work for everyone because of the possibility of so much customization and dependency that can be added to the theme.

    Downloads isn't currently compatible with 1.3, so you'd do well to remove anything related to that in the first place icon_smile As for protecting your files, obviously you would need to do something with that.

    'installed' should be '1' (true) - e.g. you are working with an 'already installed' version. when starting with a fresh DB, you would set that to '0' (false)

    I got that error also when upgrading and starting with a custom theme, but not including the theme files in my new upgrade. this is why I switched to Andreas08 to begin with (see above).
  • I will check why the Theme is not loading the master.ini for the installer.
    It's the only reason to throw that error :-S

    --
    - Mateo T. -
    Mis principios... son mis fines

This list is based on users active over the last 60 minutes.