Package org.lealone.value

Examples of org.lealone.value.Value


        try {
            if (isDebugEnabled()) {
                debugCode("updateClob(" + quote(columnLabel) + ", x);");
            }
            checkClosed();
            Value v;
            if (x == null) {
                v = ValueNull.INSTANCE;
            } else {
                v = conn.createClob(x.getCharacterStream(), -1);
            }
View Full Code Here


        try {
            if (isDebugEnabled()) {
                debugCode("updateClob(" + quote(columnLabel) + ", x, " + length + "L);");
            }
            checkClosed();
            Value v = conn.createClob(x, length);
            update(columnLabel, v);
        } catch (Exception e) {
            throw logAndConvert(e);
        }
    }
View Full Code Here

            list = patchedRows.get(result.getRowId());
            if (list == null) {
                list = result.currentRow();
            }
        }
        Value value = list[columnIndex - 1];
        wasNull = value == ValueNull.INSTANCE;
        return value;
    }
View Full Code Here

    //## Java 1.6 ##
    public NClob getNClob(int columnIndex) throws SQLException {
        try {
            int id = getNextId(TraceObject.CLOB);
            debugCodeAssign("NClob", TraceObject.CLOB, id, "getNClob(" + columnIndex + ")");
            Value v = get(columnIndex);
            return v == ValueNull.INSTANCE ? null : new JdbcClob(conn, v, id);
        } catch (Exception e) {
            throw logAndConvert(e);
        }
    }
View Full Code Here

    //## Java 1.6 ##
    public NClob getNClob(String columnLabel) throws SQLException {
        try {
            int id = getNextId(TraceObject.CLOB);
            debugCodeAssign("NClob", TraceObject.CLOB, id, "getNClob(" + columnLabel + ")");
            Value v = get(columnLabel);
            return v == ValueNull.INSTANCE ? null : new JdbcClob(conn, v, id);
        } catch (Exception e) {
            throw logAndConvert(e);
        }
    }
View Full Code Here

        if (rowData == compare) {
            return 0;
        }
        for (int i = 0, len = indexColumns.length; i < len; i++) {
            int index = columnIds[i];
            Value v = compare.getValue(index);
            if (v == null) {
                // can't compare further
                return 0;
            }
            int c = compareValues(rowData.getValue(index), v, indexColumns[i].sortType);
View Full Code Here

        try {
            if (isDebugEnabled()) {
                debugCode("updateNCharacterStream(" + columnIndex + ", x, " + length + "L);");
            }
            checkClosed();
            Value v = conn.createClob(x, length);
            update(columnIndex, v);
        } catch (Exception e) {
            throw logAndConvert(e);
        }
    }
View Full Code Here

        try {
            if (isDebugEnabled()) {
                debugCode("updateNCharacterStream(" + quote(columnLabel) + ", x, " + length + "L);");
            }
            checkClosed();
            Value v = conn.createClob(x, length);
            update(columnLabel, v);
        } catch (Exception e) {
            throw logAndConvert(e);
        }
    }
View Full Code Here

        Mode mode = database.getMode();
        if (mode.uniqueIndexSingleNull) {
            return false;
        } else if (mode.uniqueIndexSingleNullExceptAllColumnsAreNull) {
            for (int index : columnIds) {
                Value v = newRow.getValue(index);
                if (v != ValueNull.INSTANCE) {
                    return false;
                }
            }
            return true;
        }
        for (int index : columnIds) {
            Value v = newRow.getValue(index);
            if (v == ValueNull.INSTANCE) {
                return true;
            }
        }
        return false;
View Full Code Here

    public void setString(int parameterIndex, String x) throws SQLException {
        try {
            if (isDebugEnabled()) {
                debugCode("setString(" + parameterIndex + ", " + quote(x) + ");");
            }
            Value v = x == null ? (Value) ValueNull.INSTANCE : ValueString.get(x);
            setParameter(parameterIndex, v);
        } catch (Exception e) {
            throw logAndConvert(e);
        }
    }
View Full Code Here

TOP

Related Classes of org.lealone.value.Value

Copyright © 2018 www.massapicom. 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.