Package java.sql

Examples of java.sql.Clob.truncate()


      this.rs = this.stmt.executeQuery("SELECT * FROM testClobTruncate");
      this.rs.next();

      Clob clob = this.rs.getClob(1);
      clob.truncate(3);

      Reader reader = clob.getCharacterStream();
      char[] buf = new char[8];
      int charsRead = reader.read(buf);

View Full Code Here


        _outputStream.close();
        _outputStream = null;
      } else if (_lob instanceof Clob) {
        Clob clob = (Clob) _lob;
        clob.truncate(0);

        if (_writer != null)
          _writer.close();

        _writer = clob.setCharacterStream(0);
View Full Code Here

        if (_lob instanceof Blob) {
          Blob blob = (Blob) _lob;
          blob.truncate(length);
        } else if (_lob instanceof Clob) {
          Clob clob = (Clob) _lob;
          clob.truncate(length);
        }
        break;
      case OracleModule.OCI_D_ROWID:
        break;
      }
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.