older versions

 

Common Upgrade Issues

This page is designed as a companion page to Debugging Upgrade Errors. Reading the companion page first will help you learn more about how xTuple ERP upgrade packages are assembled--and how you can dis-assemble them to fix errors encountered when upgrading from one version of xTuple ERP to the next.

You can also learn about issues related to individual upgrade packages on the Version-Specific Upgrade Issues page.

Once you have a better understanding of upgrade packages, you will find this page useful for fixing common--and also version-specific--errors encountered during the version upgrade process. If you encounter errors that are not currently listed on this page, please consider becoming a content contributor.

In between fixes, it is important to log out of the updater program before running the update script again.

ERROR: syntax error at or near "(" at character 578

The following erorr was encountered while trying to import 322to330alpha/createObsolete_tax.sql into the database:  ERROR: syntax error at or near "(" at character 578.  QPSQL: Unable to create query

This error has been brought to our attention recently by people migrating from 3.2.2 to 3.3.0.  The reason for this error is due to running PostgreSQL v.8.1.x.  The short answer is to upgrade to the latest supported version of Postgres, that information can be found here: http://www.xtuple.org/SupportedPostgresVersions

Check for Duplicate Sales Order Line Item Number

You have one or more Sales Orders with duplicate Line Item Numbers.

SELECT *
FROM (SELECT coitem_cohead_id, coitem_linenumber, count(*)
FROM coitem
GROUP BY coitem_cohead_id, coitem_linenumber
HAVING count(*) > 1) AS data;

 

Run this until ZERO records are updated.

 

BEGIN;
UPDATE coitem SET coitem_linenumber = 1+(select max(coitem_linenumber)
FROM coitem where coitem_cohead_id = coheadid)
FROM (SELECT max(coitem_id) AS coitemid, coitem_cohead_id AS coheadid ,coitem_linenumber
FROM coitem
GROUP BY coitem_cohead_id, coitem_linenumber HAVING count(*) > 1) AS data
WHERE coitem_id = coitemid;

ROLLBACK OR COMMIT

Check for Duplicate Invoice Line Item Number

You have one or more Invoices with duplicate Line Item Numbers.

SELECT *
FROM (SELECT invcitem_invchead_id, invcitem_linenumber, count(*)
FROM invcitem
GROUP BY invcitem_invchead_id, invcitem_linenumber
HAVING count(*) > 1) AS data;

Run this until ZERO records are updated. 

BEGIN;
UPDATE invcitem SET invcitem_linenumber = 1+(select max(invcitem_linenumber)
FROM invcitem where invcitem_invchead_id = invcheadid)
FROM (SELECT max(invcitem_id) AS invcitemid, invcitem_invchead_id AS invcheadid ,invcitem_linenumber
FROM invcitem
GROUP BY invcitem_invchead_id, invcitem_linenumber HAVING count(*) > 1) AS data
WHERE invcitem_id = invcitemid;

ROLLBACK OR COMMIT

ERROR: role "admin" does not exist

PSQL: Unable to create query.

This error is due to the new naming convention for the administrative user in xTuple. Create the user 'admin' to repair this error.

CREATE USER admin WITH PASSWORD 'admin'
CREATEDB CREATEUSER
IN GROUP openmfg;