Project: talenddataquality
Issue TDQ-6686: overview report generate failed when one table name in my analyzed db has a long name
1. create a dbconnection make sure it has a long name table. 2. create a overview report about the connection. 3. generate report, get error. {code} !MESSAGE 2013-01-07 15:00:50,097 ERROR org.talend.dq.persistence.DatabasePersistence - org.hibernate.exception.DataException: could not insert: [org.talend.dataprofiler.datamart.hibernate.TdqOverviewIndvalue] !STACK 0 org.hibernate.exception.DataException: could not insert: [org.talend.dataprofiler.datamart.hibernate.TdqOverviewIndvalue] org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:77) org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43) org.hibernate.id.insert.AbstractReturningDelegate.performInsert(AbstractReturningDelegate.java:40) org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:2093) org.hibernate.persister.entity.AbstractEntityPersister.insert(AbstractEntityPersister.java:2573) org.hibernate.action.EntityIdentityInsertAction.execute(EntityIdentityInsertAction.java:47) org.hibernate.engine.ActionQueue.execute(ActionQueue.java:248) org.hibernate.event.def.AbstractSaveEventListener.performSaveOrReplicate(AbstractSaveEventListener.java:290) org.hibernate.event.def.AbstractSaveEventListener.performSave(AbstractSaveEventListener.java:180) org.hibernate.event.def.AbstractSaveEventListener.saveWithGeneratedId(AbstractSaveEventListener.java:108) org.hibernate.event.def.DefaultSaveOrUpdateEventListener.saveWithGeneratedOrRequestedId(DefaultSaveOrUpdateEventListener.java:186) org.hibernate.event.def.DefaultSaveEventListener.saveWithGeneratedOrRequestedId(DefaultSaveEventListener.java:33) org.hibernate.event.def.DefaultSaveOrUpdateEventListener.entityIsTransient(DefaultSaveOrUpdateEventListener.java:175) org.hibernate.event.def.DefaultSaveEventListener.performSaveOrUpdate(DefaultSaveEventListener.java:27) org.hibernate.event.def.DefaultSaveOrUpdateEventListener.onSaveOrUpdate(DefaultSaveOrUpdateEventListener.java:70) org.hibernate.impl.SessionImpl.fireSave(SessionImpl.java:535) org.hibernate.impl.SessionImpl.save(SessionImpl.java:523) org.hibernate.impl.SessionImpl.save(SessionImpl.java:519) sun.reflect.GeneratedMethodAccessor11.invoke(Unknown Source) sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) java.lang.reflect.Method.invoke(Unknown Source) org.hibernate.context.ThreadLocalSessionContext$TransactionProtectionWrapper.invoke(ThreadLocalSessionContext.java:301) $Proxy19.save(Unknown Source) org.talend.dq.persistence.DatabasePersistence.persist(DatabasePersistence.java:133) org.talend.dataprofiler.core.tdq.action.ReportDocGenerator.historizeData(ReportDocGenerator.java:450) org.talend.dataprofiler.core.tdq.action.ReportDocGenerator.generate(ReportDocGenerator.java:263) org.talend.dataprofiler.core.tdq.ui.action.GenerateReportFileAction$1.run(GenerateReportFileAction.java:126) org.eclipse.core.internal.jobs.Worker.run(Worker.java:54) Caused by: com.mysql.jdbc.MysqlDataTruncation: Data truncation: Data too long for column 'TV_NAME' at row 1 com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3376) com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3310) com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1853) com.mysql.jdbc.MysqlIO.sqlQueryDirect(MysqlIO.java:1976) com.mysql.jdbc.ConnectionImpl.execSQL(ConnectionImpl.java:2503) com.mysql.jdbc.PreparedStatement.executeInternal(PreparedStatement.java:1737) com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:2022) com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1940) com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1925) org.hibernate.id.IdentityGenerator$GetGeneratedKeysDelegate.executeAndExtract(IdentityGenerator.java:73) org.hibernate.id.insert.AbstractReturningDelegate.performInsert(AbstractReturningDelegate.java:33)	... 25 more {code}
Story points: 3