Forum

Welcome to ProjeQtOr new Forum. We migrated old forum to the new website.
You will find all your posts here, with your usual account.
Just one point : you’ll have to reinitialize your password. Use “Lost password” feature.

Migration from 4.5 ...
 
Notifications
Clear all

Migration from 4.5 to 5.5 with errors on postgresql

2 Posts
2 Users
0 Reactions
5,817 Views
(@pipobru)
Posts: 180
Active Member
Topic starter
 
[#3638]

Hello,
i have this errors on the migration:
2016-09-06 08:15:20.366 ** ERROR ** Exception-[42P07] SQLSTATE[42P07]: Duplicate table: 7 ERROR: relation "tenderstatus" already exists
2016-09-06 08:15:20.366 ** ERROR ** For query : CREATE TABLE tenderstatus (
id serial,
name varchar(100) DEFAULT NULL,
color varchar(7) DEFAULT NULL,
sortOrder numeric(3) DEFAULT NULL,
isWaiting numeric(1) DEFAULT '0',
isReceived numeric(1) DEFAULT '0',
isNotSelect numeric(1) DEFAULT '0',
isSelected numeric(1) DEFAULT '0',
idle numeric(1) DEFAULT '0',
PRIMARY KEY (id)
) ;
2016-09-06 08:15:20.366 ** ERROR ** Strack trace :
2016-09-06 08:15:20.366 ** ERROR ** #0 Sql->query called at [/var/www/html/db/maintenanceFunctions.php:71]
2016-09-06 08:15:20.366 ** ERROR ** #1 runScript called at [/var/www/html/db/maintenance.php:100]
2016-09-06 08:15:20.366 ** ERROR ** #2 include called at [/var/www/html/tool/loginCheck.php:121]
2016-09-06 08:15:20.367 ===== TRACE =====
2016-09-06 08:15:20.367 ===== TRACE ===== Error # 1 => SQL error while executing maintenance query for version V5.5.0 (see above message)
2016-09-06 08:15:20.367 ===== TRACE =====
2016-09-06 08:15:20.367 ===== TRACE ===== **********************************************
2016-09-06 08:15:20.367 ===== TRACE =====
2016-09-06 08:15:20.367
** ERROR ** Exception-[42809] SQLSTATE[42809]: Wrong object type: 7 ERROR: "tenderstatus" is an index
LINE 1: INSERT INTO tenderstatus (name, color, sortOrder, idle, isWa...
^
2016-09-06 08:15:20.367
** ERROR ** For query : INSERT INTO tenderstatus (name, color, sortOrder, idle, isWaiting, isReceived, isNotSelect, isSelected) VALUES
('request to send', '#ffa500', '10', '0', '0', '0', '0', '0'),
('waiting for reply', '#f08080', '20', '0', '1', '0', '0', '0'),
('out of date answer', '#c0c0c0', '30', '0', '0', '1', '1', '0'),
('incomplete file', '#c0c0c0', '40', '0', '0', '1', '1', '0'),
('admissible', '#87ceeb', '50', '0', '0', '1', '0', '0'),
('short list', '#4169e1', '60', '0', '0', '1', '0', '0'),
('not selected', '#c0c0c0', '70', '0', '0', '1', '1', '0'),
('selected', '#98fb98', '80', '0', '0', '1', '0', '1');
2016-09-06 08:15:20.367
** ERROR ** Strack trace :
2016-09-06 08:15:20.367
** ERROR ** #0 Sql->query called at [/var/www/html/db/maintenanceFunctions.php:71]
2016-09-06 08:15:20.367
** ERROR ** #1 runScript called at [/var/www/html/db/maintenance.php:100]
2016-09-06 08:15:20.367
** ERROR ** #2 include called at [/var/www/html/tool/loginCheck.php:121]
2016-09-06 08:15:20.367 ===== TRACE =====
2016-09-06 08:15:20.367 ===== TRACE ===== Error # 2 => SQL error while executing maintenance query for version V5.5.0 (see above message)
2016-09-06 08:15:20.367 ===== TRACE =====
2016-09-06 08:15:20.367 ===== TRACE =====
**********************************************

I have droped the index tenderstatus on table tender and re run sql for create table and add line.


 
Posted : 06 Sep 2016 10H37
babynus
(@babynus)
Posts: 14966
Main Contributor Admin
 

Issue recorded as Ticket #2293

It seems PostgreSql does not allow to have eindex and table with same name...

Fiw would be to change in /db/projeqtor_V5.5.0.sql

CREATE INDEX tenderStatus ON `${prefix}tender` (idStatus);

to

CREATE INDEX tenderStatusIndex ON `${prefix}tender` (idStatus);

I will test this and deploy fix soon.


 
Posted : 06 Sep 2016 13H39
Share:

Scroll to Top