Advanced Customization > Services and Infrastructure Customization > Creating Large Objects (LOBs) > Modeling Large Objects > Inline BLOBs
  
Inline BLOBs
INLINEBLOBs combine the features of SMALLBLOB and BLOB to provide better performance when data is small, but still allow for large data storage capability. An attribute that is stored as an INLINEBLOB uses two columns:
A VARCHAR2(4000) column
A BLOB column
Each object is examined at runtime and, when the data is small enough, it is stored in the VARCHAR(4000) column; otherwise, it is stored in the BLOB column. When the data is stored in the VARCHAR(4000) column, no additional datastore calls are required to read the BLOB data.
Using an INLINEBLOB introduces a fixed cost in terms of storage (two columns are used instead of one) and additional processing at runtime. However, when the majority of data is stored “inline” with the table, this cost is negligible in comparison to the performance benefits. If most of the data exceeds the 4000-byte limit, BLOB storage is probably more appropriate. However, if it is known that all data will never exceed the 4000-byte limit, SMALLBLOB should be used.