Example usage for java.sql DatabaseMetaData attributeNullableUnknown

List of usage examples for java.sql DatabaseMetaData attributeNullableUnknown

Introduction

In this page you can find the example usage for java.sql DatabaseMetaData attributeNullableUnknown.

Prototype

short attributeNullableUnknown

To view the source code for java.sql DatabaseMetaData attributeNullableUnknown.

Click Source Link

Document

Indicates that whether NULL values are allowed is not known.

Usage

From source file:net.starschema.clouddb.jdbc.BQDatabaseMetadata.java

private String nullableAsInt(String mode) {
    if (mode == null) {
        return String.valueOf(DatabaseMetaData.attributeNullableUnknown);
    }//from  ww w.j  a v a 2s  .  c o m
    if ("NULLABLE".equals(mode)) {
        return String.valueOf(DatabaseMetaData.attributeNullable);
    }
    if ("REQUIRED".equals(mode)) {
        return String.valueOf(DatabaseMetaData.attributeNoNulls);
    }
    if ("REPEATED".equals(mode)) {
        return String.valueOf(DatabaseMetaData.attributeNullableUnknown);
    }
    return String.valueOf(DatabaseMetaData.attributeNullableUnknown);
}