Examples of wasNull()


Examples of com.alibaba.druid.util.jdbc.LocalResultSet.wasNull()

        Assert.assertTrue(rs.next());
        Assert.assertFalse(rs.next());
        Assert.assertTrue(rs.previous());
        Assert.assertFalse(rs.previous());
        rs.getInt(1);
        Assert.assertTrue(rs.wasNull());
        rs.updateObject(1, 2);
        Assert.assertEquals(2, rs.getInt(1));
        Assert.assertFalse(rs.wasNull());
        rs.close();
    }
View Full Code Here

Examples of com.j256.ormlite.support.DatabaseResults.wasNull()

    foo.name = nameArg + " not that";
    assertEquals(nameArg, fieldType.extractJavaFieldToSqlArgValue(foo));

    DatabaseResults resultMock = createMock(DatabaseResults.class);
    expect(resultMock.findColumn("name")).andReturn(0);
    expect(resultMock.wasNull(0)).andReturn(false);
    replay(resultMock);
    assertEquals(nameResult, fieldType.resultToJava(resultMock, new HashMap<String, Integer>()));
    verify(resultMock);
  }
View Full Code Here

Examples of com.mysql.cluster.ndbj.NdbResultSet.wasNull()

            Map<String, NdbBlob> attr2Blob =
              blobMap.get(objectClasses.get(oc));
            blob = attr2Blob.get(attrName);
          } else {
            attrValBytes = ocRs.getStringBytes(attrName);
            if (ocRs.wasNull()) {
              continue;
            }
          }
          AttributeType attributeType =
            DirectoryServer.getAttributeType(
View Full Code Here

Examples of com.sun.star.sdbc.XRow.wasNull()

      do {
        // Obtain URL of child.
        String aId = xContentAccess.queryContentIdentifierString();
        // First column: Title (column numbers are 1-based!)
        String aTitle = xRow.getString(1);
        if (aTitle.length() == 0 && xRow.wasNull());
        //ignore
        else
          files.add(aTitle);
      } while (xResultSet.next()); // next child
    }
View Full Code Here

Examples of java.sql.CallableStatement.wasNull()

        put (DB.nm_microsite, oCall.getString(3));
        put (DB.gu_workarea, oCall.getString(4).trim());
        put (DB.nm_pageset, oCall.getString(5));

        sField = oCall.getObject(6);
        if (!oCall.wasNull()) put(DB.vs_stamp, (String) sField);

        sField = oCall.getObject(7);
        if (!oCall.wasNull()) put(DB.id_language, ((String) sField).trim());

        sField = oCall.getObject(8);
View Full Code Here

Examples of java.sql.ResultSet.wasNull()

          ResultSet rs = ps.executeQuery();
          if (rs.next()) {
            info.reloid = rs.getInt(1);
            info.attnum = rs.getShort(2);
            int specificType = rs.getInt(3);
            if (!rs.wasNull()) {
              info.type = specificType;
            }
          }
        } finally {
          if (ps != null) {
View Full Code Here

Examples of java.sql.ResultSet.wasNull()

  case Types.LONGVARBINARY:*/
  switch (translateDBColumnType(md.getColumnTypeName(i))) {
  case STRING :
    String str = rs.getString(i);
   
    if (rs.wasNull()) {
      vals[i - 1] = Utils.missingValue();
    } else {
      Double index = (Double)nominalIndexes[i - 1].get(str);
      if (index == null) {
        index = new Double(nominalStrings[i - 1].size());
View Full Code Here

Examples of java.sql.ResultSet.wasNull()

    }
    break;
  case TEXT:
    String txt = rs.getString(i);
   
    if (rs.wasNull()) {
      vals[i - 1] = Utils.missingValue();
    } else {
      Double index = (Double)nominalIndexes[i - 1].get(txt);
      if (index == null) {
        index = new Double(nominalStrings[i - 1].size());
View Full Code Here

Examples of java.sql.ResultSet.wasNull()

      vals[i - 1] = index.doubleValue();
    }
    break;
  case BOOL:
    boolean boo = rs.getBoolean(i);
    if (rs.wasNull()) {
      vals[i - 1] = Utils.missingValue();
    } else {
      vals[i - 1] = (boo ? 1.0 : 0.0);
    }
    break;
View Full Code Here

Examples of java.sql.ResultSet.wasNull()

    break;
  case DOUBLE:
    //    BigDecimal bd = rs.getBigDecimal(i, 4);
    double dd = rs.getDouble(i);
    // Use the column precision instead of 4?
    if (rs.wasNull()) {
      vals[i - 1] = Utils.missingValue();
    } else {
      //      newInst.setValue(i - 1, bd.doubleValue());
      vals[i - 1] =  dd;
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.