Java Code Examples for java.sql.ResultSetMetaData#columnNullableUnknown()

The following examples show how to use java.sql.ResultSetMetaData#columnNullableUnknown() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: RowSetMetaDataTests.java    From dragonwell8_jdk with GNU General Public License v2.0 5 votes vote down vote up
@DataProvider(name = "validSetNullableValues")
private Object[][] validSetNullableValues() {
    return new Object[][]{
        {ResultSetMetaData.columnNoNulls},
        {ResultSetMetaData.columnNullable},
        {ResultSetMetaData.columnNullableUnknown}
    };
}
 
Example 2
Source File: RowSetMetaDataTests.java    From TencentKona-8 with GNU General Public License v2.0 5 votes vote down vote up
@DataProvider(name = "validSetNullableValues")
private Object[][] validSetNullableValues() {
    return new Object[][]{
        {ResultSetMetaData.columnNoNulls},
        {ResultSetMetaData.columnNullable},
        {ResultSetMetaData.columnNullableUnknown}
    };
}
 
Example 3
Source File: RowSetMetaDataTests.java    From jdk8u60 with GNU General Public License v2.0 5 votes vote down vote up
@DataProvider(name = "validSetNullableValues")
private Object[][] validSetNullableValues() {
    return new Object[][]{
        {ResultSetMetaData.columnNoNulls},
        {ResultSetMetaData.columnNullable},
        {ResultSetMetaData.columnNullableUnknown}
    };
}
 
Example 4
Source File: RowSetMetaDataTests.java    From openjdk-jdk8u with GNU General Public License v2.0 5 votes vote down vote up
@DataProvider(name = "validSetNullableValues")
private Object[][] validSetNullableValues() {
    return new Object[][]{
        {ResultSetMetaData.columnNoNulls},
        {ResultSetMetaData.columnNullable},
        {ResultSetMetaData.columnNullableUnknown}
    };
}
 
Example 5
Source File: RowSetMetaDataTests.java    From openjdk-jdk8u-backup with GNU General Public License v2.0 5 votes vote down vote up
@DataProvider(name = "validSetNullableValues")
private Object[][] validSetNullableValues() {
    return new Object[][]{
        {ResultSetMetaData.columnNoNulls},
        {ResultSetMetaData.columnNullable},
        {ResultSetMetaData.columnNullableUnknown}
    };
}
 
Example 6
Source File: RowSetMetaDataTests.java    From openjdk-jdk9 with GNU General Public License v2.0 5 votes vote down vote up
@DataProvider(name = "validSetNullableValues")
private Object[][] validSetNullableValues() {
    return new Object[][]{
        {ResultSetMetaData.columnNoNulls},
        {ResultSetMetaData.columnNullable},
        {ResultSetMetaData.columnNullableUnknown}
    };
}
 
Example 7
Source File: RowSetMetaDataTests.java    From jdk8u-jdk with GNU General Public License v2.0 5 votes vote down vote up
@DataProvider(name = "validSetNullableValues")
private Object[][] validSetNullableValues() {
    return new Object[][]{
        {ResultSetMetaData.columnNoNulls},
        {ResultSetMetaData.columnNullable},
        {ResultSetMetaData.columnNullableUnknown}
    };
}
 
Example 8
Source File: RowSetMetaDataTests.java    From hottub with GNU General Public License v2.0 5 votes vote down vote up
@DataProvider(name = "validSetNullableValues")
private Object[][] validSetNullableValues() {
    return new Object[][]{
        {ResultSetMetaData.columnNoNulls},
        {ResultSetMetaData.columnNullable},
        {ResultSetMetaData.columnNullableUnknown}
    };
}
 
Example 9
Source File: SFResultSetMetaData.java    From snowflake-jdbc with Apache License 2.0 5 votes vote down vote up
public int isNullable(int column)
{
  if (nullables != null)
  {
    return nullables.get(column - 1);
  }
  else
  {
    return ResultSetMetaData.columnNullableUnknown;
  }
}
 
Example 10
Source File: RowSetMetaDataTests.java    From jdk8u_jdk with GNU General Public License v2.0 5 votes vote down vote up
@DataProvider(name = "validSetNullableValues")
private Object[][] validSetNullableValues() {
    return new Object[][]{
        {ResultSetMetaData.columnNoNulls},
        {ResultSetMetaData.columnNullable},
        {ResultSetMetaData.columnNullableUnknown}
    };
}
 
Example 11
Source File: FabricResultSetMetaData.java    From fabric-jdbc-connector with Apache License 2.0 4 votes vote down vote up
public int isNullable(int column) throws SQLException {
    return ResultSetMetaData.columnNullableUnknown;
}
 
Example 12
Source File: EthResultSetMetaData.java    From eth-jdbc-connector with Apache License 2.0 4 votes vote down vote up
@Override
public int isNullable(int column) throws SQLException {
    return ResultSetMetaData.columnNullableUnknown;
}
 
Example 13
Source File: CloudSpannerResultSetMetaDataTest.java    From spanner-jdbc with MIT License 4 votes vote down vote up
private Builder withNullableUnknown() {
  this.nulls = ResultSetMetaData.columnNullableUnknown;
  return this;
}
 
Example 14
Source File: CsvResultSetMetaData.java    From jdbc-driver-csv with GNU Lesser General Public License v3.0 4 votes vote down vote up
@Override
public int isNullable(int column) throws SQLException {
    return ResultSetMetaData.columnNullableUnknown;
}
 
Example 15
Source File: TdsCore.java    From jTDS with GNU Lesser General Public License v2.1 4 votes vote down vote up
/**
 * Process a TDS 4.2 column format token.
 *
 * @throws IOException
 * @throws ProtocolException
 */
private void tds4ColFormatToken()
    throws IOException, ProtocolException {

    final int pktLen = in.readShort();

    int bytesRead = 0;
    int numColumns = 0;
    while (bytesRead < pktLen) {
        if (numColumns > columns.length) {
            throw new ProtocolException("Too many columns in TDS_COL_FMT packet");
        }
        ColInfo col = columns[numColumns];

        if (serverType == Driver.SQLSERVER) {
            col.userType = in.readShort();

            int flags = in.readShort();

            col.nullable = ((flags & 0x01) != 0)?
                                ResultSetMetaData.columnNullable:
                                   ResultSetMetaData.columnNoNulls;
            col.isCaseSensitive = (flags & 0x02) != 0;
            col.isWriteable = (flags & 0x0C) != 0;
            col.isIdentity = (flags & 0x10) != 0;
        } else {
            // Sybase does not send column flags
            col.isCaseSensitive = false;
            col.isWriteable = true;

            if (col.nullable == ResultSetMetaData.columnNoNulls) {
                col.nullable = ResultSetMetaData.columnNullableUnknown;
            }

            col.userType = in.readInt();
        }
        bytesRead += 4;

        bytesRead += TdsData.readType(in, col);

        numColumns++;
    }

    if (numColumns != columns.length) {
        throw new ProtocolException("Too few columns in TDS_COL_FMT packet");
    }

    endOfResults = false;
}
 
Example 16
Source File: DBFResultSetMataData.java    From sis with Apache License 2.0 4 votes vote down vote up
/**
 * @see java.sql.ResultSetMetaData#isNullable(int)
 */
@Override public int isNullable(int column) {
    logStep("isNullable", column);
    return ResultSetMetaData.columnNullableUnknown; // TODO Check if somes settings exists for that in field descriptor.
}