[ http://jira.dspace.org/jira/browse/DS-110?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=10784#action_10784 ]
Van Ly edited comment on DS-110 at 11/16/09 5:41 AM: ----------------------------------------------------- Note: after upgrading to DSpace 1.5.2 this problem went away, I was able to add and replace items with the bulk import mechanism. On DSpace 1.5.0 upgraded from 1.4.2 as described by http://wiki.dspace.org/index.php/To_upgrade_without_overwriting I am able to `add' an item with the command $ds/bin/dsrun org.dspace.app.itemimport.ItemImport \ -a \ -e $dsEperson \ -c $dsCollection \ -s $dsItemCopy \ -m $dsItemCopy/mapfile \ > $dsItemCopy/$basedir.log \ 2> $dsItemCopy/$basedir.err but when the same item is used in a `replace' operation using $ds/bin/dsrun org.dspace.app.itemimport.ItemImport \ -r \ -e $dsEperson \ -c $dsCollection \ -s $dsItemCopy \ -m $dsItemCopy/mapfile \ > $dsItemCopy/$basedir.log \ 2> $dsItemCopy/$basedir.err it fails on `PSQLException: ERROR: duplicate key violates unique constraint "handle_handle_key"'; in the dublin_core.xml file there is no line of the kind <dcvalue element="identifier" qualifier="uri">N/A</dcvalue> I'll try upgrading to 1.5.2 to see if that fixes the problem. -- log 1 Destination collections: 2 Owning Collection: name_of_collection 3 Replacing: number/number 4 Adding item from directory numberXnumber 5 Loading dublin core from /tmp/dspace-import/numberXnumber/dublin_core.xml 6 Schema: dc Element: identifier Qualifier: systemid Value: numberXnumber 7 Schema: dc Element: description Qualifier: pubcategory Value: description_of_thing 8 Schema: dc Element: date Qualifier: issued Value: number 9 Schema: dc Element: title Qualifier: publication Value: description_of_thing 10 Schema: dc Element: title Qualifier: journalname Value: description_of_thing 11 Schema: dc Element: publisher Qualifier: none Value: description_of_thing 12 Schema: dc Element: description Qualifier: volume Value: number 13 Schema: dc Element: description Qualifier: issue Value: number 14 Schema: dc Element: description Qualifier: startpage Value: number 15 Schema: dc Element: description Qualifier: endpage Value: number 16 Schema: dc Element: contributor Qualifier: author Value: name_of_author 17 Schema: dc Element: contributor Qualifier: department Value: name_of_department 18 Schema: dc Element: contributor Qualifier: author Value: N/A 19 Schema: dc Element: contributor Qualifier: author Value: N/A 20 Schema: dc Element: contributor Qualifier: author Value: N/A 21 Schema: dc Element: title Qualifier: none Value: N/A 22 Schema: dc Element: format Qualifier: mimetype Value: application/pdf 23 Processing contents file: /tmp/dspace-import/numberXnumber/contents 24 Bitstream: name_of_thing.pdf 25 Processing handle file: handle 26 read handle: 'number/number' 27 org.postgresql.util.PSQLException: ERROR: duplicate key violates unique constraint "handle_handle_key" -- log -- -- error log 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) -- error log -- -- Van was (Author: vly): On DSpace 1.5.0 upgraded from 1.4.2 as described by http://wiki.dspace.org/index.php/To_upgrade_without_overwriting I am able to `add' an item with the command $ds/bin/dsrun org.dspace.app.itemimport.ItemImport \ -a \ -e $dsEperson \ -c $dsCollection \ -s $dsItemCopy \ -m $dsItemCopy/mapfile \ > $dsItemCopy/$basedir.log \ 2> $dsItemCopy/$basedir.err but when the same item is used in a `replace' operation using $ds/bin/dsrun org.dspace.app.itemimport.ItemImport \ -r \ -e $dsEperson \ -c $dsCollection \ -s $dsItemCopy \ -m $dsItemCopy/mapfile \ > $dsItemCopy/$basedir.log \ 2> $dsItemCopy/$basedir.err it fails on `PSQLException: ERROR: duplicate key violates unique constraint "handle_handle_key"'; in the dublin_core.xml file there is no line of the kind <dcvalue element="identifier" qualifier="uri">N/A</dcvalue> I'll try upgrading to 1.5.2 to see if that fixes the problem. -- log 1 Destination collections: 2 Owning Collection: name_of_collection 3 Replacing: number/number 4 Adding item from directory numberXnumber 5 Loading dublin core from /tmp/dspace-import/numberXnumber/dublin_core.xml 6 Schema: dc Element: identifier Qualifier: systemid Value: numberXnumber 7 Schema: dc Element: description Qualifier: pubcategory Value: description_of_thing 8 Schema: dc Element: date Qualifier: issued Value: number 9 Schema: dc Element: title Qualifier: publication Value: description_of_thing 10 Schema: dc Element: title Qualifier: journalname Value: description_of_thing 11 Schema: dc Element: publisher Qualifier: none Value: description_of_thing 12 Schema: dc Element: description Qualifier: volume Value: number 13 Schema: dc Element: description Qualifier: issue Value: number 14 Schema: dc Element: description Qualifier: startpage Value: number 15 Schema: dc Element: description Qualifier: endpage Value: number 16 Schema: dc Element: contributor Qualifier: author Value: name_of_author 17 Schema: dc Element: contributor Qualifier: department Value: name_of_department 18 Schema: dc Element: contributor Qualifier: author Value: N/A 19 Schema: dc Element: contributor Qualifier: author Value: N/A 20 Schema: dc Element: contributor Qualifier: author Value: N/A 21 Schema: dc Element: title Qualifier: none Value: N/A 22 Schema: dc Element: format Qualifier: mimetype Value: application/pdf 23 Processing contents file: /tmp/dspace-import/numberXnumber/contents 24 Bitstream: name_of_thing.pdf 25 Processing handle file: handle 26 read handle: 'number/number' 27 org.postgresql.util.PSQLException: ERROR: duplicate key violates unique constraint "handle_handle_key" -- log -- -- error log 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) -- error log -- -- Van > Batch Import modification > ------------------------- > > Key: DS-110 > URL: http://jira.dspace.org/jira/browse/DS-110 > Project: DSpace 1.x > Issue Type: Bug > Affects Versions: 1.5.1 > Reporter: Rui Ramos > Assignee: Stuart Lewis > > Batch Import Modification with dsrun still fails: > Executing: > $DSHOME/bin/dsrun org.dspace.app.itemimport.ItemImport --replace > --eperson=mana...@repo.up.pt --collection='10216/6765' --source=export > --mapfile=mapfile > with replace tries to insert: > org.postgresql.util.PSQLException: ERROR: duplicate key violates unique > constraint "handle_handle_key" > at > org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:1512) > at > org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1297) > at > org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:188) > at > org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:430) > at > org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:346) > at > org.postgresql.jdbc2.AbstractJdbc2Statement.executeUpdate(AbstractJdbc2Statement.java:300) > at > org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:101) > at > org.dspace.storage.rdbms.DatabaseManager.execute(DatabaseManager.java:1301) > at > org.dspace.storage.rdbms.DatabaseManager.update(DatabaseManager.java:657) > at org.dspace.handle.HandleManager.createHandle(HandleManager.java:206) > at org.dspace.content.InstallItem.installItem(InstallItem.java:114) > at org.dspace.app.itemimport.ItemImport.addItem(ItemImport.java:672) > at > org.dspace.app.itemimport.ItemImport.replaceItems(ItemImport.java:585) > at org.dspace.app.itemimport.ItemImport.main(ItemImport.java:425) > org.postgresql.util.PSQLException: ERROR: duplicate key violates unique > constraint "handle_handle_key" -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.dspace.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira ------------------------------------------------------------------------------ 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-devel mailing list Dspace-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/dspace-devel