From: James Ahlborn Date: Tue, 12 Jul 2011 02:37:31 +0000 (+0000) Subject: do not allow creation of table with unsupported column type X-Git-Tag: jackcess-1.2.5~7 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=150cf4f38bc6f05bfa8e28696d65943e5f4daca5;p=jackcess.git do not allow creation of table with unsupported column type git-svn-id: https://svn.code.sf.net/p/jackcess/code/jackcess/trunk@568 f203690c-595d-4dc9-a70b-905162fa7fd2 --- diff --git a/src/java/com/healthmarketscience/jackcess/Column.java b/src/java/com/healthmarketscience/jackcess/Column.java index b4afdbb..b216623 100644 --- a/src/java/com/healthmarketscience/jackcess/Column.java +++ b/src/java/com/healthmarketscience/jackcess/Column.java @@ -483,6 +483,11 @@ public class Column implements Comparable { } Database.validateIdentifierName(getName(), format.MAX_COLUMN_NAME_LENGTH, "column"); + + if(getType().isUnsupported()) { + throw new IllegalArgumentException( + "Cannot create column with unsupported type " + getType()); + } if(isVariableLength() != getType().isVariableLength()) { throw new IllegalArgumentException("invalid variable length setting");