Trouble after updates 1.6 and extension 1.2.1

Post Reply
fahmisalim
Sponsor
Sponsor
Posts: 320
Joined: 12 May 2015, 08:33
Name: Fahmi Salim
Location: Indonesia BSD City
Company Name: AIMan
Contact:

Trouble after updates 1.6 and extension 1.2.1

Post by fahmisalim »

When Updates, I cannot go detail of project, result show:
Database Error: 1054 - Unknown column 'parent_entity_id' in 'where clause'
Query: select * from app_reports where entities_id='31' and reports_type='entity' and created_by='19' and parent_entity_id='30' and parent_item_id='16'
Page: /index.php?module=items/items&path=30-16/31
User avatar
support
Site Admin
Posts: 6215
Joined: 19 Oct 2014, 18:22
Name: Sergey Kharchishin
Location: Russia, Evpatoriya

Re: Trouble after updates 1.6 and extension 1.2.1

Post by support »

hi

you did not upgrade database
see http://rukovoditel.net/new_release.php?version=1.6
Then upgrade database
To upgrade database download version 1.6 and load "install" folder only
Run script: http://your_domain_name/install/autoupdate/from_1.5_to_1.6.php
Note: in "install/db_updates/" folder you can find all database update for each version.
fahmisalim
Sponsor
Sponsor
Posts: 320
Joined: 12 May 2015, 08:33
Name: Fahmi Salim
Location: Indonesia BSD City
Company Name: AIMan
Contact:

Re: Trouble after updates 1.6 and extension 1.2.1

Post by fahmisalim »

I did, and result is: "You have already run this update" and error still:
Database Error: 1054 - Unknown column 'parent_entity_id' in 'where clause'
Query: select * from app_reports where entities_id='29' and reports_type='entity' and created_by='19' and parent_entity_id='28' and parent_item_id='39'
Page: /index.php?module=items/items&path=28-39/29
User avatar
support
Site Admin
Posts: 6215
Joined: 19 Oct 2014, 18:22
Name: Sergey Kharchishin
Location: Russia, Evpatoriya

Re: Trouble after updates 1.6 and extension 1.2.1

Post by support »

strange, then try to run query manually using phpmyadmin
ALTER TABLE `app_reports` ADD `parent_entity_id` INT NOT NULL DEFAULT '0' , ADD `parent_item_id` INT NOT NULL DEFAULT '0' ;
fahmisalim
Sponsor
Sponsor
Posts: 320
Joined: 12 May 2015, 08:33
Name: Fahmi Salim
Location: Indonesia BSD City
Company Name: AIMan
Contact:

Re: Trouble after updates 1.6 and extension 1.2.1

Post by fahmisalim »

still have error
Error: 500 Internal Server Error
fahmisalim
Sponsor
Sponsor
Posts: 320
Joined: 12 May 2015, 08:33
Name: Fahmi Salim
Location: Indonesia BSD City
Company Name: AIMan
Contact:

Re: Trouble after updates 1.6 and extension 1.2.1

Post by fahmisalim »

Can I re install and using exixting database?
User avatar
support
Site Admin
Posts: 6215
Joined: 19 Oct 2014, 18:22
Name: Sergey Kharchishin
Location: Russia, Evpatoriya

Re: Trouble after updates 1.6 and extension 1.2.1

Post by support »

no, you can't

probably none of sql queries runs during upgrade

so there is full list of data base changes
ALTER TABLE `app_reports` ADD `users_groups` TEXT NULL ;

ALTER TABLE `app_attachments` ADD `container` VARCHAR(16) NOT NULL DEFAULT '' ;

ALTER TABLE `app_reports` ADD `parent_entity_id` INT NOT NULL DEFAULT '0' , ADD `parent_item_id` INT NOT NULL DEFAULT '0' ;
ALTER TABLE `app_reports` ADD INDEX `idx_parent_id` (`parent_id`);
ALTER TABLE `app_reports` ADD INDEX `idx_parent_entity_id` (`parent_entity_id`);
ALTER TABLE `app_reports` ADD INDEX `idx_parent_item_id` (`parent_item_id`);
run them manually and let me know if it works

did you use 1.5 version, right?
fahmisalim
Sponsor
Sponsor
Posts: 320
Joined: 12 May 2015, 08:33
Name: Fahmi Salim
Location: Indonesia BSD City
Company Name: AIMan
Contact:

Re: Trouble after updates 1.6 and extension 1.2.1

Post by fahmisalim »

Response from manual query:

Error
SQL query:

ALTER TABLE `app_reports` ADD `users_groups` TEXT NULL ;


MySQL said: Documentation

#1060 - Duplicate column name 'users_groups'

Response from website:
Error: 500 Internal Server Error

But some project success to open the detail

I'm using version 1.4
User avatar
support
Site Admin
Posts: 6215
Joined: 19 Oct 2014, 18:22
Name: Sergey Kharchishin
Location: Russia, Evpatoriya

Re: Trouble after updates 1.6 and extension 1.2.1

Post by support »

well not it's clear
Note: in "install/db_updates/" folder you can find all database update for each version.
it means you have to upgrade database to 1.5
so run manually update_1.5.sql

Code: Select all

CREATE TABLE IF NOT EXISTS `app_related_items` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `entities_id` int(11) NOT NULL,
  `items_id` int(11) NOT NULL,
  `related_entities_id` int(11) NOT NULL,
  `related_items_id` int(11) NOT NULL,
  PRIMARY KEY (`id`),
  KEY `idx_entities_id` (`entities_id`),
  KEY `idx_items_id` (`items_id`),
  KEY `idx_related_entities_id` (`related_entities_id`),
  KEY `idx_related_items_id` (`related_items_id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=1 ;

ALTER TABLE `app_reports` ADD `parent_id` INT NOT NULL DEFAULT '0' AFTER `id`;

ALTER TABLE `app_entities` ADD `display_in_menu` TINYINT(1) NULL DEFAULT '0' AFTER `name`;

CREATE TABLE IF NOT EXISTS `app_attachments` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `form_token` varchar(64) NOT NULL,
  `filename` varchar(255) NOT NULL,
  `date_added` date NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=1;
Post Reply