irm-1.6-b3/MDB/ibase.php
/**
     * Convert a text value into a DBMS specific format that is suitable to
     * compose query statements.
     *
     * @param resource  $prepared_query query handle from prepare()
     * @param           $parameter
     * @param           $lob
     * @return string text string that represents the given argument value in
     *      a DBMS specific format.
     * @access private
     */
Convert a text value into a DBMS specific format that is suitable to
compose query statements.

@param resource  $prepared_query query handle from prepare()
@param           $parameter
@param           $lob
@return string text string that represents the given argument value in
a DBMS specific format.
@access private
Convert a text value into a DBMS specific format that is suitable to compose query statements . @param resource $prepared_query query handle from prepare () @param $parameter @param $lob @return string text string that represents the given argument value in a DBMS specific format . @access private
function _getLobValue($prepared_query, $parameter, $lob)
    {
        if (MDB::isError($connect = $this->connect())) {
            return $connect;
        }
        $value   = '';  
        if (!$this->transaction_id = @ibase_trans(IBASE_COMMITTED, $this->connection)) {
            return($this->raiseError(MDB_ERROR, NULL, NULL, '_getLobValue: Could not start a new transaction: '.@ibase_errmsg()));
        }
        if (($lo = @ibase_blob_create($this->auto_commit ? $this->connection : $this->transaction_id))) {
            while (!$this->endOfLob($lob)) {
                if (MDB::isError($result = $this->readLob($lob, $data, $this->options['lob_buffer_length']))) {
                    break;
                }
                if (@ibase_blob_add($lo, $data) === false) {
                    $result = $this->raiseError(MDB_ERROR, NULL, NULL,
                        '_getLobValue - Could not add data to a large object: ' . @ibase_errmsg());
                    break;
                }
            }
            if (MDB::isError($result)) {
                @ibase_blob_cancel($lo);
            } else {
                $value = @ibase_blob_close($lo);
            }
        } else {
            $result = $this->raiseError(MDB_ERROR, NULL, NULL,
                'Get LOB field value' . @ibase_errmsg());
        }
        if (!isset($this->query_parameters[$prepared_query])) {
            $this->query_parameters[$prepared_query]       = array(0, '');
            $this->query_parameter_values[$prepared_query] = array();
        }
        $query_parameter = count($this->query_parameters[$prepared_query]);
        $this->query_parameter_values[$prepared_query][$parameter] = $query_parameter;
        $this->query_parameters[$prepared_query][$query_parameter] = $value;
        $value = '?';
        if (!$this->auto_commit) {
            $this->commit();
        }
        return $value;
    }
function _getLobValue ( $ prepared_query , $ parameter , $ lob ) { if ( MDB :: isError ( $ connect = $ this -> connect ( ) ) ) { return $ connect ; } $ value = '' ; if ( ! $ this -> transaction_id = @ ibase_trans ( IBASE_COMMITTED , $ this -> connection ) ) { return ( $ this -> raiseError ( MDB_ERROR , NULL , NULL , '_getLobValue: Could not start a new transaction: ' . @ ibase_errmsg ( ) ) ) ; } if ( ( $ lo = @ ibase_blob_create ( $ this -> auto_commit ? $ this -> connection : $ this -> transaction_id ) ) ) { while ( ! $ this -> endOfLob ( $ lob ) ) { if ( MDB :: isError ( $ result = $ this -> readLob ( $ lob , $ data , $ this -> options [ 'lob_buffer_length' ] ) ) ) { break ; } if ( @ ibase_blob_add ( $ lo , $ data ) === false ) { $ result = $ this -> raiseError ( MDB_ERROR , NULL , NULL , '_getLobValue - Could not add data to a large object: ' . @ ibase_errmsg ( ) ) ; break ; } } if ( MDB :: isError ( $ result ) ) { @ ibase_blob_cancel ( $ lo ) ; } else { $ value = @ ibase_blob_close ( $ lo ) ; } } else { $ result = $ this -> raiseError ( MDB_ERROR , NULL , NULL , 'Get LOB field value' . @ ibase_errmsg ( ) ) ; } if ( ! isset ( $ this -> query_parameters [ $ prepared_query ] ) ) { $ this -> query_parameters [ $ prepared_query ] = array ( 0 , '' ) ; $ this -> query_parameter_values [ $ prepared_query ] = array ( ) ; } $ query_parameter = count ( $ this -> query_parameters [ $ prepared_query ] ) ; $ this -> query_parameter_values [ $ prepared_query ] [ $ parameter ] = $ query_parameter ; $ this -> query_parameters [ $ prepared_query ] [ $ query_parameter ] = $ value ; $ value = '?' ; if ( ! $ this -> auto_commit ) { $ this -> commit ( ) ; } return $ value ; }
Convert a text value into a DBMS specific format that is suitable to
 compose query statements.
Convert a text value into a DBMS specific format that is suitable to compose query statements .
// DEAL WITH ME