Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0014085Openbravo ERPA. Platformpublic2010-07-29 12:042022-02-01 08:08
dalsasua 
Triage Platform Base 
normalmajoralways
acknowledgedopen 
20Ubuntu 9.04
 
 
Core
No
0014085: Inconsistent unique restriction in AD_PACKAGE table
There exists a unique restriction in src-db/database/model/tables/AD_PACKAGE.xml:
      <unique name="AD_PACKAGE_NAME">
        <unique-column name="NAME"/>
      </unique>
This makes that two modules that have two AD_PACKAGE rows with same name (but different java package name) makes the compilation to fail.
Install two modules
Change src-db/database/model/tables/AD_PACKAGE.xml of one of them, so both have same name (and different java package name)
Run ant smartbuild -Dlocal=no -Dapply.on.create=true -Dforce=true
You will obtain error:

     [java] 272959 ERROR - Error while inserting into the database: ERROR: llave duplicada viola restricción de unicidad «ad_package_name»
     [java] org.postgresql.util.PSQLException: ERROR: llave duplicada viola restricción de unicidad «ad_package_name»
     [java] at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:1548)
     [java] at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1316)
     [java] at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:191)
     [java] at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:452)
     [java] at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:351)
     [java] at org.postgresql.jdbc2.AbstractJdbc2Statement.executeUpdate(AbstractJdbc2Statement.java:305)
     [java] at org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:101)
     [java] at org.apache.ddlutils.platform.PlatformImplBase.insert(PlatformImplBase.java:1576)
     [java] at org.apache.ddlutils.platform.PlatformImplBase.upsert(PlatformImplBase.java:1489)
     [java] at org.apache.ddlutils.platform.PlatformImplBase.alterData(PlatformImplBase.java:756)
     [java] at org.openbravo.ddlutils.task.AlterDatabaseDataAll.doExecute(AlterDatabaseDataAll.java:168)
     [java] at org.openbravo.ddlutils.task.BaseDatabaseTask.execute(BaseDatabaseTask.java:87)
     [java] at org.openbravo.ddlutils.task.AlterDatabaseJava.main(AlterDatabaseJava.java:34)
...
Remove the restriction, if possible
No tags attached.
Issue History
2010-07-29 12:04dalsasuaNew Issue
2010-07-29 12:04dalsasuaAssigned To => alostale
2010-08-02 08:12alostaleStatusnew => scheduled
2010-08-02 08:12alostalefix_in_branch => pi
2012-04-02 15:29alostaleTypedefect => design defect
2012-04-02 15:29alostalefix_in_branchpi =>
2012-09-24 23:32AugustoMauchNote Added: 0052487
2012-09-24 23:32AugustoMauchPriorityurgent => normal
2017-03-31 14:36alostaleStatusscheduled => acknowledged
2017-04-10 14:34alostaleAssigned Toalostale => platform
2022-02-01 08:08alostaleAssigned Toplatform => Triage Platform Base

Notes
(0052487)
AugustoMauch   
2012-09-24 23:32   
Impact: low
Plan: mid