Your Browser is not longer supported

Please use Google Chrome, Mozilla Firefox or Microsoft Edge to view the page correctly
Loading...

{{viewport.spaceProperty.prod}}

SQL_BLOB_OBJ_CREATE - SQLbocr

SQL_BLOB_OBJ_CREATE creates a new BLOB and outputs the generated REF value. The input parameters include the database name and the REF value of the class to which the new BLOB is to belong. You can also specify the REF value of an existing object of this class. The following values are entered in the BLOB table when a new object is created:

  • The BLOB is assigned an object number that is unique within that class. This object number is assigned sequentially.

  • The BLOB attributes UPDATED and CREATED are assigned the current time stamp. All other attributes are set in accordance with their default values.

The BLOB value of the newly created BLOB has the length 0.

This CLI call requires the INSERT and SELECT privileges for BLOB tables, as well as the UPDATE privilege for the obj_ref column of the BLOB table.

CLI declaration in C:

void SQL_BLOB_OBJ_CREATE( char *REFvalue
          ,char const *CatalogId
          ,struct SQLda_t *SQLda);

CLI declaration in COBOL:

IDENTIFICATION DIVISION.
PROGRAM-ID. SQLbocr IS PROTOTYPE.
DATA DIVISION.
LINKAGE SECTION.
   01 REFvalue PIC X(237).
   01 CatalogId PIC X(31).
   COPY SQLCA.      *> for group item SQLda.
PROCEDURE DIVISION USING REFvalue, CatalogId, SQLda.
END PROGRAM SQLbocr.


REFvalue

REF value of the class or of an existing object from the same class. The exact structure of REF values is described on "Column definitions".

CatalogId

Unqualified name of the database in which the table is located. CatalogId is an unqualified name (see section "Unqualified names"). If necessary, this name must be padded with blanks up to a length of 31 characters or terminated with a null byte. If you wish to use the default database name, simply enter a null byte or a string of blanks instead of the database name.

SQLda

Diagnostics area.