{"action":"created","issue":{"url":"https://api.github.com/repos/am-impact/amnav/issues/28","labels_url":"https://api.github.com/repos/am-impact/amnav/issues/28/labels{/name}","comments_url":"https://api.github.com/repos/am-impact/amnav/issues/28/comments","events_url":"https://api.github.com/repos/am-impact/amnav/issues/28/events","html_url":"https://github.com/am-impact/amnav/issues/28","id":69153500,"number":28,"title":"Can't upgrade from 1.4.3","user":{"login":"bgarrant","id":2436728,"avatar_url":"https://avatars.githubusercontent.com/u/2436728?v=3","gravatar_id":"","url":"https://api.github.com/users/bgarrant","html_url":"https://github.com/bgarrant","followers_url":"https://api.github.com/users/bgarrant/followers","following_url":"https://api.github.com/users/bgarrant/following{/other_user}","gists_url":"https://api.github.com/users/bgarrant/gists{/gist_id}","starred_url":"https://api.github.com/users/bgarrant/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bgarrant/subscriptions","organizations_url":"https://api.github.com/users/bgarrant/orgs","repos_url":"https://api.github.com/users/bgarrant/repos","events_url":"https://api.github.com/users/bgarrant/events{/privacy}","received_events_url":"https://api.github.com/users/bgarrant/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-04-17T14:48:58Z","updated_at":"2015-04-20T23:31:19Z","closed_at":null,"body":"I am trying to upgreade to latest version 1.5.3 and I just keep getting an error and rollback message.  I am on version 1.4.3."},"comment":{"url":"https://api.github.com/repos/am-impact/amnav/issues/comments/94592099","html_url":"https://github.com/am-impact/amnav/issues/28#issuecomment-94592099","issue_url":"https://api.github.com/repos/am-impact/amnav/issues/28","id":94592099,"user":{"login":"engram-design","id":1221575,"avatar_url":"https://avatars.githubusercontent.com/u/1221575?v=3","gravatar_id":"","url":"https://api.github.com/users/engram-design","html_url":"https://github.com/engram-design","followers_url":"https://api.github.com/users/engram-design/followers","following_url":"https://api.github.com/users/engram-design/following{/other_user}","gists_url":"https://api.github.com/users/engram-design/gists{/gist_id}","starred_url":"https://api.github.com/users/engram-design/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/engram-design/subscriptions","organizations_url":"https://api.github.com/users/engram-design/orgs","repos_url":"https://api.github.com/users/engram-design/repos","events_url":"https://api.github.com/users/engram-design/events{/privacy}","received_events_url":"https://api.github.com/users/engram-design/received_events","type":"User","site_admin":false},"created_at":"2015-04-20T23:31:19Z","updated_at":"2015-04-20T23:31:19Z","body":"@hubertprein FYI, I've made the following changes to the migration files, and seems to upgrade properly.\r\n\r\nChanging the table name from `amnav_pages` to `amnav_nodes` in `m150217_112800_AmNav_expandPageData.php` fixes the first issue - as the previous migration renamed this table already, so `amnav_pages` doesn't exist.\r\n\r\n```\r\n// Add columns\r\n$this->addColumnAfter(**'amnav_nodes'**, 'locale', array(ColumnType::Locale, 'default' => null), 'entryId');\r\n\r\n// Add index\r\n$this->createIndex(**'amnav_nodes'**, 'entryId,locale');\r\n\r\n// Update existing records with the primary locale\r\ncraft()->db->createCommand()->update(**'amnav_nodes'**, array('locale' => craft()->i18n->getPrimarySiteLocaleId()));\r\n```\r\n\r\nAnd in `m150403_093000_AmNav_nodesWithElements.php`, it's having issues dropping an index from the old table - because of the above fix, the table has already been renamed, and the `entryId,locale` index has been created on the `amnav_nodes` table. As such, there's no need to rename back to the old table name, but you still need to drop the index, because the column is being renamed later in that migration.\r\n\r\n```\r\n//$this->renameTable('amnav_nodes', 'amnav_pages');\r\n$this->dropIndex('amnav_pages', 'entryId,locale');\r\n//$this->renameTable('amnav_pages', 'amnav_nodes');\r\n\r\n```\r\n\r\nHope that helps! "}}