Freeing a temporary LOB
The DBMS_LOB.FREETEMPORARY procedure explicitly frees a temporary BLOB or CLOB, releasing the space from your default temporary tablespace. The header for this procedure is:
After a call to FREETEMPORARY, the LOB locator that was freed (lob_loc in the pre‐vious specification) is marked as invalid. If an invalid LOB locator is assigned to another LOB locator through an assignment operation in PL/SQL, then the target of the as‐signment is also freed and marked as invalid.
lob_loc IN [ BLOB | CLOB CHARACTER SET ANY_CS ]) RETURN INTEGER;
Note that while this function returns true (1) or false (0), it does not return a BOOLEAN datatype.
|Working with LOBs|||||441|
• If a user modifies a temporary LOB while another locator is pointing to it, a copy (referred to by Oracle as a deep copy) of that LOB is made. The different locators will then no longer see the same data. To minimize these deep copies, use the NO‐COPY compiler hint whenever you’re passing LOB locators as arguments.
• To make a temporary LOB permanent, you must call the DBMS_LOB.COPY pro‐ gram and copy the temporary LOB into a permanent LOB.