diff options
Diffstat (limited to 'src/java/com/healthmarketscience/jackcess/Column.java')
-rw-r--r-- | src/java/com/healthmarketscience/jackcess/Column.java | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/java/com/healthmarketscience/jackcess/Column.java b/src/java/com/healthmarketscience/jackcess/Column.java index 5987ae3..76012ef 100644 --- a/src/java/com/healthmarketscience/jackcess/Column.java +++ b/src/java/com/healthmarketscience/jackcess/Column.java @@ -321,9 +321,9 @@ public class Column implements Comparable<Column> { if(getType() == null) { throw new IllegalArgumentException("must have type"); } - if((getName() == null) || (getName().trim().length() == 0)) { - throw new IllegalArgumentException("must have valid name"); - } + Database.validateIdentifierName(getName(), format.MAX_COLUMN_NAME_LENGTH, + "column"); + if(isVariableLength() != getType().isVariableLength()) { throw new IllegalArgumentException("invalid variable length setting"); } |