mco_uda_blob_append

Append to a BLOB field.

Prototype

 
    MCO_RET mco_uda_blob_append(	/*IN*/ const mco_uda_object_handle_p obj, 
                    /*IN*/ unsigned short field_no, 
                    /*IN*/ const void * val, 
                    /*IN*/ uint4 size );
 

Arguments

obj The object handle

field_no

The field number (must be between 0 and struct_info.field_count - 1)

val

The address of a mco_uda_value_t variable to receive the data

size

The number of bytes to be appended to the BLOB

Description

Append to a BLOB field.

 

Return Codes

MCO_S_OK Field data successfully updated
MCO_E_UDA_FIELD_NOT_FOUND

Invalid fieldno - field not found in this class or struct

MCO_E_ILLEGAL_PARAM

The type of field is not a BLOB

Example

     
    Application snippet:
        
     
    int main(int argc, char* argv[])
    {
        MCO_RET rc;
        mco_uda_object_handle_t obj;
        unsigned short blob_field_no = 1;
        void * append_buf;
        uint4 append_size = 1024;
         
        ...
        append_buf =  malloc(append_size);
        /* Copy BLOB data into append_buf */
        ...
        rc = mco_uda_blob_append( &obj, blob_field_no, append_buf, append_size);
        
        ...
    }
 

Files

Header file:
mcouda.h
Source file:
mcouda.c
Library:
libmcouda.a