Tag Archives: CLOB

How to find size used for the storage of BLOB or CLOB variable

lobsize returns the size (in bytes) used for the storage of BLOB or CLOB variable. Syntax: lobsize(BLOB_CLOB) Example: # How much space spent for a clob? Local Clbfile MY_CLOB(0) MY_SIZE=lobsize(MY_CLOB) : # Returns 1016 (stores 508 characters) My_CLOB=string$(50,space$(10))+space$(9) : # Assign a 509 character string MY_SIZE=lobsize(MY_CLOB) : # Returns 66550 (MY_CLOB has been automatically enlarged)… Read More »

Extracts the Nth character of a CHAR or CLOB variable

This function extracts the Nth character of a CHAR or CLOB variable. This function runs much faster than the usual functions such as mid$or seg$ when managing large CLOB data. Syntax: EXTRACTED_CHARACTER=Xgetchar(CLOB_SOURCE,POSITION) Parameters: CLOB_SOURCE has been declared by using a Clbfile or a Char  POSITION has been declared by using an Integer EXTRACTED_CHARACTER has been… Read More »