[hibernate-issues] [Hibernate-JIRA] Updated: (HHH-6789) StringIndexOutOfBoundsException at TemplatedViolatedConstraintNameExtracter.extractUsingTemplate
Gail Badner (JIRA)
noreply at atlassian.com
Wed Nov 2 13:51:19 EDT 2011
[ http://opensource.atlassian.com/projects/hibernate/browse/HHH-6789?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Gail Badner updated HHH-6789:
-----------------------------
Fix Version/s: 4.0.0.next
> StringIndexOutOfBoundsException at TemplatedViolatedConstraintNameExtracter.extractUsingTemplate
> ------------------------------------------------------------------------------------------------
>
> Key: HHH-6789
> URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-6789
> Project: Hibernate Core
> Issue Type: Bug
> Components: core
> Affects Versions: 4.0.0.CR5
> Environment: PostgreSQL
> Reporter: Dimitris Zenios
> Fix For: 4.0.0.next
>
>
> TemplatedViolatedConstraintNameExtracter.extractUsingTemplate throws java.lang.StringIndexOutOfBoundsException: String index out of range: -1
> Example values
> templateStart = "violates check constraint \""
> templateEnd = "\""
> message = "new row for relation \"user_balance\" violates check constraint \"balance_check_constraint\""
> This function broke from the last commit
> https://hibernate.onjira.com/browse/HHH-4854
> In order to fix it, we have to change this on the function
> int end = message.lastIndexOf( templateEnd, start );
> to
> int end = message.indexOf( templateEnd, start );
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the hibernate-issues
mailing list