Hi;

Has anyone found a fix for

  PSQLException: ERROR: duplicate key violates unique constraint  
"handle_handle_key" ?

I've upgraded a DSpace from 1.4.2 to 1.5 and then to 1.5.2 and  
haven't done anything to the handle-server.

At both the newer versions, by batch import, I am able to `add' but  
not `replace' an item.

The newly added item is given the handle `123/89310'; the current  
state of the handle table in the postgresql database has by  
descending handle_id values:

  handle_id |   handle
-----------+-------------
      89306 | 123/89306
      89305 | 123/89305
      89304 | 123/40284
      89303 | 123/5090
      89302 | 123/4383
      89301 | 123/8301
      89300 | 123/7008

and handle_seq is 89306

The error message is:

      1  org.postgresql.util.PSQLException: ERROR: duplicate key  
violates unique constraint "handle_handle_key"
      2          at  
org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse 
(QueryExecutorImpl.java:1512)
      3          at  
org.postgresql.core.v3.QueryExecutorImpl.processResults 
(QueryExecutorImpl.java:1297)
      4          at org.postgresql.core.v3.QueryExecutorImpl.execute 
(QueryExecutorImpl.java:188)
      5          at  
org.postgresql.jdbc2.AbstractJdbc2Statement.execute 
(AbstractJdbc2Statement.java:430)
      6          at  
org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags 
(AbstractJdbc2Statement.java:346)
      7          at  
org.postgresql.jdbc2.AbstractJdbc2Statement.executeUpdate 
(AbstractJdbc2Statement.java:300)
      8          at  
org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate 
(DelegatingPreparedStatement.java:101)
      9          at  
org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate 
(DelegatingPreparedStatement.java:101)
     10          at org.dspace.storage.rdbms.DatabaseManager.execute 
(DatabaseManager.java:1301)
     11          at org.dspace.storage.rdbms.DatabaseManager.update 
(DatabaseManager.java:657)
     12          at org.dspace.handle.HandleManager.createHandle 
(HandleManager.java:206)
     13          at org.dspace.content.InstallItem.installItem 
(InstallItem.java:114)
     14          at org.dspace.app.itemimport.ItemImport.addItem 
(ItemImport.java:672)
     15          at org.dspace.app.itemimport.ItemImport.replaceItems 
(ItemImport.java:585)
     16          at org.dspace.app.itemimport.ItemImport.main 
(ItemImport.java:425)

This problem is also noted at: http://jira.dspace.org/jira/browse/DS-110

Thanks in advance.

Van Ly
vly at usyd dot edu dot au





------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech

Reply via email to