mirror of https://github.com/apache/openjpa.git
OPENJAP-664: Check length constraint onIndex name, not on the table on which index is created
git-svn-id: https://svn.apache.org/repos/asf/openjpa/trunk@680413 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
2254791f9b
commit
72b5b4def8
|
@ -3165,10 +3165,10 @@ public class DBDictionary
|
|||
buf.append("CREATE ");
|
||||
if (index.isUnique())
|
||||
buf.append("UNIQUE ");
|
||||
buf.append("INDEX ").append(index.getName());
|
||||
String indexName = checkNameLength(getFullName(index.getTable(), false),
|
||||
maxIndexNameLength, "long-index-name");
|
||||
buf.append(" ON ").append(indexName);
|
||||
String indexName = checkNameLength(index.getName(), maxIndexNameLength,
|
||||
"long-index-name");
|
||||
buf.append("INDEX ").append(indexName);
|
||||
buf.append(" ON ").append(getFullName(index.getTable(), false));
|
||||
buf.append(" (").append(Strings.join(index.getColumns(), ", ")).
|
||||
append(")");
|
||||
|
||||
|
|
Loading…
Reference in New Issue