@Override
    public String toSqlExpression() {
        if (isNullOrEmpty()) {
            return ClickHouseValues.NULL_EXPR;
        }

        return new StringBuilder().append('\'')
                .append(asDateTime(scale).format(
                        scale > 0 ? ClickHouseValues.DATETIME_FORMATTER : ClickHouseDateTimeValue.dateTimeFormatter))
                .append('\'').toString();
    }
Update value of the given object or create a new instance if {@code ref} is
null.

@param ref   object to update, could be null
@param value value
@param scale scale, only used when {@code ref} is null
@param tz    time zone, null is treated as {@code UTC}
@return same object as {@code ref} or a new instance if it's null
clickhouse-data/src/main/java/com/clickhouse/data/value/ClickHouseOffsetDateTimeValue.java