EMPTY_CLOB
A CLOB
or NCLOB
column can be initialized to a zero-length, empty CLOB
or NCLOB
using the EMPTY_CLOB
function. Both CLOB
and NCLOB
data types are initialized with the EMPTY_CLOB
function. This function initializes the LOB to a non-null value, so can be used for initializing any CLOB
or NCLOB
that has been declared as NOT NULL
.
This function is not supported in TimesTen Scaleout.
SQL syntax
EMPTY_CLOB ()
Parameters
EMPTY_CLOB
has no parameters.
Description
You can only use EMPTY_CLOB
in the VALUES
clause of an INSERT
statement or the SET
clause of an UPDATE
statement.
Examples
The following example uses the EMPTY_CLOB
function to initialize a non-null CLOB
column to a zero-length value.
Command> CREATE TABLE clob_content (id NUMBER PRIMARY KEY, clob_column CLOB NOT NULL ); -- Does not allow a NULL value Command> INSERT INTO clob_content (id, clob_column) VALUES (1, EMPTY_CLOB( ) ); 1 row inserted.