[opencms-dev] INSERT INTO CMS_CONTENTS error

Olivier Camus olivier.camus at steria.com
Mon Jan 7 09:47:52 CET 2008


Hi List !

I have a really mysterious problem (really mysterious for me ;-P ).

when I try to publish a ressource from the workplace, I get the
following exception and I don't understand why ???

Please help me ...




Publishing resources ...
Publishing folders ...
( 1 / 1 ) Publishing folder /youth-partnership/jsp/commons/ ... o.k.
... finished publishing folders
Publishing files ...
( 1 / 1 ) Publishing file /youth-partnership/jsp/commons/warning.jsp ...
Error publishing file
"/sites/default/youth-partnership/jsp/commons/warning.jsp". 
Exception org.opencms.file.CmsDataAccessException: An SQL error occurred
when executing the following query:
com.mysql.jdbc.PreparedStatement at 1ea2de1: INSERT INTO CMS_CONTENTS
(RESOURCE_ID,FILE_CONTENT,PUBLISH_TAG_FROM,PUBLISH_TAG_TO,ONLINE_FLAG)
VALUES
('f9e34df5-bae6-11dc-b3e4-001676837e8f',x'3C2540207061676520696D706F72743D226A6176612E7574696C2E2A22253E0A3C2540207061676520696D706F72743D226F72672E636F652E796F757468706172746E6572736869702E74656D706C6174652E436F65436F6E7374616E7422253E0A3C2540207461676C6962207072656669783D22636D7322207572693D22687474703A2F2F7777772E6F70656E636D732E6F72672F7461676C69622F636D7322253E0A093C250A090969662028726571756573742E67657441747472696275746528436F65436F6E7374616E742E4552524F52434F4445535F4D41502920213D206E756C6C290A0909097B0A09253E0A093C62723E0A093C7461626C6520636C6173733D22666F726D4672616D65223E0A09093C74626F64793E0A0909093C74723E0A090909093C74643E3C666F6E7420636F6C6F723D22726564223E3C623E5761726E696E67203A3C2F623E3C62723E0A090909093C250A0909090909486173687461626C65206572726F72436F646573203D2028486173687461626C652920726571756573740A0909090909090909092E67657441747472696275746528436F65436F6E7374616E742E4552524F52434F4445535F4D4150293B0A0A090909090909094C697374206C203D20436F6C6C656374696F6E732E6C6973

at
org.opencms.db.generic.CmsProjectDriver.publishFile(CmsProjectDriver.java:996)
at
org.opencms.db.generic.CmsProjectDriver.publishProject(CmsProjectDriver.java:1407)
at org.opencms.db.CmsDriverManager.publishJob(CmsDriverManager.java:5073)
at org.opencms.publish.CmsPublishThread.run(CmsPublishThread.java:141)
Caused by: org.opencms.db.CmsDbSqlException: An SQL error occurred when
executing the following query: com.mysql.jdbc.PreparedStatement at 1ea2de1:
INSERT INTO CMS_CONTENTS
(RESOURCE_ID,FILE_CONTENT,PUBLISH_TAG_FROM,PUBLISH_TAG_TO,ONLINE_FLAG)
VALUES
('f9e34df5-bae6-11dc-b3e4-001676837e8f',x'3C2540207061676520696D706F72743D226A6176612E7574696C2E2A22253E0A3C2540207061676520696D706F72743D226F72672E636F652E796F757468706172746E6572736869702E74656D706C6174652E436F65436F6E7374616E7422253E0A3C2540207461676C6962207072656669783D22636D7322207572693D22687474703A2F2F7777772E6F70656E636D732E6F72672F7461676C69622F636D7322253E0A093C250A090969662028726571756573742E67657441747472696275746528436F65436F6E7374616E742E4552524F52434F4445535F4D41502920213D206E756C6C290A0909097B0A09253E0A093C62723E0A093C7461626C6520636C6173733D22666F726D4672616D65223E0A09093C74626F64793E0A0909093C74723E0A090909093C74643E3C666F6E7420636F6C6F723D22726564223E3C623E5761726E696E67203A3C2F623E3C62723E0A090909093C250A0909090909486173687461626C65206572726F72436F646573203D2028486173687461626C652920726571756573740A0909090909090909092E67657441747472696275746528436F65436F6E7374616E742E4552524F52434F4445535F4D4150293B0A0A090909090909094C697374206C203D20436F6C6C656374696F6E732E6C6973

at
org.opencms.db.generic.CmsVfsDriver.createOnlineContent(CmsVfsDriver.java:399)
at
org.opencms.db.generic.CmsProjectDriver.publishFileContent(CmsProjectDriver.java:1071)
at
org.opencms.db.generic.CmsProjectDriver.publishNewFile(CmsProjectDriver.java:2903)
at
org.opencms.db.generic.CmsProjectDriver.publishFile(CmsProjectDriver.java:952)
... 3 more
Caused by:
com.mysql.jdbc.exceptions.MySQLIntegrityConstraintViolationException:
Duplicate entry 'f9e34df5-bae6-11dc-b3e4-001676837e8f-30' for key 1
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:931)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2985)
at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1631)
at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1723)
at com.mysql.jdbc.Connection.execSQL(Connection.java:3256)
at
com.mysql.jdbc.PreparedStatement.executeInternal(PreparedStatement.java:1313)
at
com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1585)
at
com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1500)
at
com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1485)
at
org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:102)
at
org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:102)
at
org.opencms.db.generic.CmsVfsDriver.createOnlineContent(CmsVfsDriver.java:380)
... 6 more
Statistics: published files: 1, published folders: 1, deleted folders:
0, duration: 00:00:00
Exception org.opencms.file.CmsDataAccessException: Error publishing file
"/sites/default/youth-partnership/jsp/commons/warning.jsp". 
at
org.opencms.file.CmsDataAccessException.createException(CmsDataAccessException.java:77)
at org.opencms.db.CmsDbContext.throwException(CmsDbContext.java:238)
at org.opencms.db.CmsDbContext.report(CmsDbContext.java:212)
at
org.opencms.db.generic.CmsProjectDriver.publishProject(CmsProjectDriver.java:1427)
at org.opencms.db.CmsDriverManager.publishJob(CmsDriverManager.java:5073)
at org.opencms.publish.CmsPublishThread.run(CmsPublishThread.java:141)
Caused by: org.opencms.file.CmsDataAccessException: An SQL error
occurred when executing the following query:
com.mysql.jdbc.PreparedStatement at 1ea2de1: INSERT INTO CMS_CONTENTS
(RESOURCE_ID,FILE_CONTENT,PUBLISH_TAG_FROM,PUBLISH_TAG_TO,ONLINE_FLAG)
VALUES
('f9e34df5-bae6-11dc-b3e4-001676837e8f',x'3C2540207061676520696D706F72743D226A6176612E7574696C2E2A22253E0A3C2540207061676520696D706F72743D226F72672E636F652E796F757468706172746E6572736869702E74656D706C6174652E436F65436F6E7374616E7422253E0A3C2540207461676C6962207072656669783D22636D7322207572693D22687474703A2F2F7777772E6F70656E636D732E6F72672F7461676C69622F636D7322253E0A093C250A090969662028726571756573742E67657441747472696275746528436F65436F6E7374616E742E4552524F52434F4445535F4D41502920213D206E756C6C290A0909097B0A09253E0A093C62723E0A093C7461626C6520636C6173733D22666F726D4672616D65223E0A09093C74626F64793E0A0909093C74723E0A090909093C74643E3C666F6E7420636F6C6F723D22726564223E3C623E5761726E696E67203A3C2F623E3C62723E0A090909093C250A0909090909486173687461626C65206572726F72436F646573203D2028486173687461626C652920726571756573740A0909090909090909092E67657441747472696275746528436F65436F6E7374616E742E4552524F52434F4445535F4D4150293B0A0A090909090909094C697374206C203D20436F6C6C656374696F6E732E6C6973

at
org.opencms.db.generic.CmsProjectDriver.publishFile(CmsProjectDriver.java:996)
at
org.opencms.db.generic.CmsProjectDriver.publishProject(CmsProjectDriver.java:1407)
... 2 more
Caused by: org.opencms.db.CmsDbSqlException: An SQL error occurred when
executing the following query: com.mysql.jdbc.PreparedStatement at 1ea2de1:
INSERT INTO CMS_CONTENTS
(RESOURCE_ID,FILE_CONTENT,PUBLISH_TAG_FROM,PUBLISH_TAG_TO,ONLINE_FLAG)
VALUES
('f9e34df5-bae6-11dc-b3e4-001676837e8f',x'3C2540207061676520696D706F72743D226A6176612E7574696C2E2A22253E0A3C2540207061676520696D706F72743D226F72672E636F652E796F757468706172746E6572736869702E74656D706C6174652E436F65436F6E7374616E7422253E0A3C2540207461676C6962207072656669783D22636D7322207572693D22687474703A2F2F7777772E6F70656E636D732E6F72672F7461676C69622F636D7322253E0A093C250A090969662028726571756573742E67657441747472696275746528436F65436F6E7374616E742E4552524F52434F4445535F4D41502920213D206E756C6C290A0909097B0A09253E0A093C62723E0A093C7461626C6520636C6173733D22666F726D4672616D65223E0A09093C74626F64793E0A0909093C74723E0A090909093C74643E3C666F6E7420636F6C6F723D22726564223E3C623E5761726E696E67203A3C2F623E3C62723E0A090909093C250A0909090909486173687461626C65206572726F72436F646573203D2028486173687461626C652920726571756573740A0909090909090909092E67657441747472696275746528436F65436F6E7374616E742E4552524F52434F4445535F4D4150293B0A0A090909090909094C697374206C203D20436F6C6C656374696F6E732E6C6973

at
org.opencms.db.generic.CmsVfsDriver.createOnlineContent(CmsVfsDriver.java:399)
at
org.opencms.db.generic.CmsProjectDriver.publishFileContent(CmsProjectDriver.java:1071)
at
org.opencms.db.generic.CmsProjectDriver.publishNewFile(CmsProjectDriver.java:2903)
at
org.opencms.db.generic.CmsProjectDriver.publishFile(CmsProjectDriver.java:952)
... 3 more
Caused by:
com.mysql.jdbc.exceptions.MySQLIntegrityConstraintViolationException:
Duplicate entry 'f9e34df5-bae6-11dc-b3e4-001676837e8f-30' for key 1
at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:931)
at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2985)
at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1631)
at com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1723)
at com.mysql.jdbc.Connection.execSQL(Connection.java:3256)
at
com.mysql.jdbc.PreparedStatement.executeInternal(PreparedStatement.java:1313)
at
com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1585)
at
com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1500)
at
com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1485)
at
org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:102)
at
org.apache.commons.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:102)
at
org.opencms.db.generic.CmsVfsDriver.createOnlineContent(CmsVfsDriver.java:380)
... 6 more
... the resources have been published




More information about the opencms-dev mailing list