1

I am not able to publish PDF files with filename 金融机构客户身份识别和客户身份资料及交易管理办公室备存纪录

I am getting the below error in committing deployment phase

Phase: Deployment Prepare Commit Phase failed. Unable to prepare transaction: tcm:0-21624-66560

I am getting below error in deployer logs

Caused by: org.hibernate.exception.DataException: String or binary data would be truncated.
at org.hibernate.exception.internal.SQLStateConversionDelegate.convert(SQLStateConversionDelegate.java:134) ~[hibernate-core.jar:4.0.1.Final]
at org.hibernate.exception.internal.StandardSQLExceptionConverter.convert(StandardSQLExceptionConverter.java:47) ~[hibernate-core.jar:4.0.1.Final]
at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:125) ~[hibernate-core.jar:4.0.1.Final]
at org.hibernate.engine.jdbc.spi.SqlExceptionHelper.convert(SqlExceptionHelper.java:110) ~[hibernate-core.jar:4.0.1.Final]
at org.hibernate.engine.jdbc.internal.proxy.AbstractStatementProxyHandler.continueInvocation(AbstractStatementProxyHandler.java:129) ~[hibernate-core.jar:4.0.1.Final]
at org.hibernate.engine.jdbc.internal.proxy.AbstractProxyHandler.invoke(AbstractProxyHandler.java:81) ~[hibernate-core.jar:4.0.1.Final]
at com.sun.proxy.$Proxy118.executeUpdate(Unknown Source) ~[na:na]
at org.hibernate.engine.jdbc.batch.internal.NonBatchingBatch.addToBatch(NonBatchingBatch.java:56) ~[hibernate-core.jar:4.0.1.Final]
at org.hibernate.persister.entity.AbstractEntityPersister.update(AbstractEntityPersister.java:3006) ~[hibernate-core.jar:4.0.1.Final]
at org.hibernate.persister.entity.AbstractEntityPersister.updateOrInsert(AbstractEntityPersister.java:2908) ~[hibernate-core.jar:4.0.1.Final]
at org.hibernate.persister.entity.AbstractEntityPersister.update(AbstractEntityPersister.java:3237) ~[hibernate-core.jar:4.0.1.Final]
at org.hibernate.action.internal.EntityUpdateAction.execute(EntityUpdateAction.java:113) ~[hibernate-core.jar:4.0.1.Final]
at org.hibernate.engine.spi.ActionQueue.execute(ActionQueue.java:272) ~[hibernate-core.jar:4.0.1.Final]
at org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:264) ~[hibernate-core.jar:4.0.1.Final]
at org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:187) ~[hibernate-core.jar:4.0.1.Final]
at org.hibernate.event.internal.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:326) ~[hibernate-core.jar:4.0.1.Final]
at org.hibernate.event.internal.DefaultAutoFlushEventListener.onAutoFlush(DefaultAutoFlushEventListener.java:59) ~[hibernate-core.jar:4.0.1.Final]
at org.hibernate.internal.SessionImpl.autoFlushIfRequired(SessionImpl.java:1053) ~[hibernate-core.jar:4.0.1.Final]
at org.hibernate.internal.SessionImpl.list(SessionImpl.java:1108) ~[hibernate-core.jar:4.0.1.Final]
at org.hibernate.internal.QueryImpl.list(QueryImpl.java:101) ~[hibernate-core.jar:4.0.1.Final]

Please advise .

1
  • Just to add on the above question ,I think the issue is with the size of column "URL" in BINARYVARIANTS table .I am still debugging this . Jun 10, 2014 at 11:49

1 Answer 1

1

Deployer saves the URL in URLEncoded format and if the length of that exceeds 255(default size of column length) you will see this error. I believe that's what exactly happening in your case, if you try URL encode of your filename it is 262 chars. I suggest you open a support ticket for resolution which could be increasing the column length higher than 255 to suitable length.

Alternately, you could trim the image path during the publish using the resolver or TBB by checking the length of url encoded image path (little tricky.. also you might not have a proper image path..)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.