Skip Headers
Oracle® Database SecureFiles and Large Objects Developer's Guide
11g Release 2 (11.2)

Part Number E10645-01
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Index
Index
Go to Master Index
Master Index
Go to Feedback page
Contact Us

Go to previous page
Previous
Go to next page
Next
View PDF

A LOB Demonstration Files

This appendix describes files distributed with the database that demonstrate how LOBs are used in supported programmatic environments. This appendix contains these topics:

PL/SQL LOB Demonstration Files

The following table lists PL/SQL demonstration files. These files are installed in $ORACLE_HOME/rdbms/demo/lobs/plsql/. A driver program, lobdemo.sql, that calls these files is found in the same directory.

Table A-1 PL/SQL Demonstration Examples

File Name Description Usage Information

fclose_c.sql

Closing a BFILE with CLOSE

Closing a BFILE with CLOSE

fclose_f.sql

Closing a BFILE with FILECLOSE

Closing a BFILE with FILECLOSE

fclosea.sql

Closing all open BFILEs

Closing All Open BFILEs with FILECLOSEALL

fcompare.sql

Comparing all or parts of two BFILEs

Comparing All or Parts of Two BFILES

fcopyloc.sql

Copying a LOB locator for a BFILE

Assigning a BFILE Locator

fdisplay.sql

Displaying BFILE data

Displaying BFILE Data

fexists.sql

Checking if a BFILE exists

Determining Whether a BFILE Exists

ffilopen.sql

Opening a BFILE with FILEOPEN

Opening a BFILE with FILEOPEN

ffisopen.sql

Checking if the BFILE is OPEN with FILEISOPEN

Determining Whether a BFILE Is Open with FILEISOPEN

fgetdir.sql

Getting the directory object name and filename of a BFILE

Getting Directory Object Name and File Name of a BFILE

finsert.sql

Inserting row containing a BFILE by initializing a BFILE locator

Inserting a Row Containing a BFILE

fisopen.sql

Checking if the BFILE is open with ISOPEN

Determining Whether a BFILE Is Open Using ISOPEN

flength.sql

Getting the length of a BFILE

Getting the Length of a BFILE

floadlob.sql

Loading a LOB with BFILE data

Loading a LOB with BFILE Data

fopen.sql

Opening a BFILE with OPEN

Opening a BFILE with OPEN

fpattern.sql

Checking if a pattern exists in a BFILE using instr

Checking If a Pattern Exists in a BFILE Using INSTR

fread.sql

Reading data from a BFILE

Reading Data from a BFILE

freadprt.sql

Reading portion of a BFILE data using substr

Reading a Portion of BFILE Data Using SUBSTR

fupdate.sql

Updating a BFILE by initializing a BFILE locator

Updating a BFILE by Initializing a BFILE Locator

lappend.sql

Appending one LOB to another

Appending One LOB to Another

lcompare.sql

Comparing all or part of LOB

Comparing All or Part of Two LOBs

lcopy.sql

Copying all or part of a LOB to another LOB

Copying All or Part of One LOB to Another LOB

lcopyloc.sql

Copying a LOB locator

Copying All or Part of One LOB to Another LOB

ldisplay.sql

Displaying LOB data

Displaying LOB Data

lerase.sql

Erasing part of a LOB

Erasing Part of a LOB

linsert.sql

Inserting a row by initializing LOB locator bind variable

Inserting a Row by Initializing a LOB Locator Bind Variable

linstr.sql

Seeing if pattern exists in LOB (instr)

Patterns: Checking for Patterns in a LOB Using INSTR

lisopen.sql

Seeing if LOB is open

Determining Whether a LOB is Open

listemp.sql

Seeing if LOB is temporary

Determining Whether a LOB instance Is Temporary

lldblobf.sql

Using DBMS_LOB.LOADBLOBFROMFILE to load a BLOB with data from a BFILE

Loading a BLOB with Data from a BFILE

lldclobf.sql

Using DBMS_LOB.LOADCLOBFROMFILE to load a CLOB or NCLOB with data from a BFILE

Loading a CLOB or NCLOB with Data from a BFILE

lldclobs.sql

Using DBMS_LOB.LOADCLOBFROMFILE to load segments of a stream of data from a BFILE into different CLOBs

Loading a CLOB or NCLOB with Data from a BFILE

llength.sql

Getting the length of a LOB

Length: Determining the Length of a LOB

lloaddat.sql

Loading a LOB with BFILE data

Loading a LOB with Data from a BFILE

lobuse.sql

Examples of LOB API usage.

Creating Persistent and Temporary LOBs in PL/SQL

lread.sql

Reading data from LOB

Reading Data from a LOB

lsubstr.sql

Reading portion of LOB (substr)

Reading a Portion of a LOB (SUBSTR)

ltrim.sql

Trimming LOB data

Trimming LOB Data

lwrite.sql

Writing data to a LOB

Writing Data to a LOB

lwriteap.sql

Writing to the end of LOB (write append)

Appending to a LOB


OCI LOB Demonstration Files

The following table lists OCI demonstration files. These files are installed in $ORACLE_HOME/rdbms/demo/lobs/oci/. A driver program, lobdemo.c, that calls these files is found in the same directory, as is the header file lobdemo.h.

Table A-2 OCI Demonstration Examples

File Name Description Usage Information

fclose_c.c

Closing a BFILE with CLOSE

Closing a BFILE with CLOSE

fclose_f.c

Closing a BFILE with FILECLOSE

Closing a BFILE with FILECLOSE

fclosea.c

Closing all open BFILEs

Closing All Open BFILEs with FILECLOSEALL

fcopyloc.c

Copying a LOB locator for a BFILE

Assigning a BFILE Locator

fdisplay.c

Displaying BFILE data

Displaying BFILE Data

fexists.c

Checking if a BFILE exists

Determining Whether a BFILE Exists

ffilopen.c

Opening a BFILE with FILEOPEN

Opening a BFILE with FILEOPEN

ffisopen.c

Checking if the BFILE is OPEN with FILEISOPEN

Determining Whether a BFILE Is Open with FILEISOPEN

fgetdir.c

Getting the directory object name and filename of a BFILE

Getting Directory Object Name and File Name of a BFILE

finsert.c

Inserting row containing a BFILE by initializing a BFILE locator

Inserting a Row Containing a BFILE

fisopen.c

Checking if the BFILE is open with ISOPEN

Determining Whether a BFILE Is Open Using ISOPEN

flength.c

Getting the length of a BFILE

Getting the Length of a BFILE

floadlob.c

Loading a LOB with BFILE data

Loading a LOB with BFILE Data

fopen.c

Opening a BFILE with OPEN

Opening a BFILE with OPEN

fread.c

Reading data from a BFILE

Reading Data from a BFILE

fupdate.c

Updating a BFILE by initializing a BFILE locator

Updating a BFILE by Initializing a BFILE Locator

lappend.c

Appending one LOB to another

Appending One LOB to Another

lcopy.c

Copying all or part of a LOB to another LOB

Copying All or Part of One LOB to Another LOB

lcopyloc.c

Copying a LOB locator

Copying All or Part of One LOB to Another LOB

ldisbuf.c

Disabling LOB buffering (persistent LOBs)

Disabling LOB Buffering

ldisplay.c

Displaying LOB data

Displaying LOB Data

lequal.c

Seeing if one LOB locator is equal to another

Equality: Checking If One LOB Locator Is Equal to Another

lerase.c

Erasing part of a LOB

Erasing Part of a LOB

lgetchar.c

Getting character set id

Determining Character Set ID

lgetchfm.c

Getting character set form of the foreign language ad text, ad_fltextn

Determining Character Set Form

linit.c

Seeing if a LOB locator is initialized

Determining Whether LOB Locator Is Initialized

linsert.c

Inserting a row by initializing LOB locator bind variable

Inserting a Row by Initializing a LOB Locator Bind Variable

lisopen.c

Seeing if LOB is open

Determining Whether a LOB is Open

listemp.c

Seeing if LOB is temporary

Determining Whether a LOB instance Is Temporary

llength.c

Getting the length of a LOB

Length: Determining the Length of a LOB

lloaddat.c

Loading a LOB with BFILE data

Loading a LOB with Data from a BFILE

lread.c

Reading data from LOB

Reading Data from a LOB

lreadarr.c

Reading data from an array of LOB locators

LOB Array Read

ltrim.c

Trimming LOB data

Trimming LOB Data

lwrite.c

Writing data to a LOB

Writing Data to a LOB

lwritearr.c

Writing data into an array of LOB locators

LOB Array Write

lwriteap.c

Writing to the end of LOB (write append)

Appending to a LOB


COM OO4O LOB Demonstration Files

The following table lists COM OO4O demonstration files. These files are installed in $ORACLE_HOME/rdbms/demo/lobs/vb/.

Table A-3 COM OO4O Demonstration Examples

File Name Description Usage Information

fclose_c.bas

Closing a BFILE with CLOSE

Closing a BFILE with CLOSE

fclosea.bas

Closing all open BFILEs

Closing All Open BFILEs with FILECLOSEALL

fcompare.bas

Comparing all or parts of two BFILEs

Comparing All or Parts of Two BFILES

fdisplay.bas

Displaying BFILE data

Displaying BFILE Data

fexists.bas

Checking if a BFILE exists

Determining Whether a BFILE Exists

fgetdir.bas

Getting the directory object name and filename of a BFILE

Getting Directory Object Name and File Name of a BFILE

finsert.bas

Inserting row containing a BFILE by initializing a BFILE locator

Inserting a Row Containing a BFILE

fisopen.bas

Checking if the BFILE is open with ISOPEN

Determining Whether a BFILE Is Open Using ISOPEN

flength.bas

Getting the length of a BFILE

Getting the Length of a BFILE

floadlob.bas

Loading a LOB with BFILE data

Loading a LOB with BFILE Data

fopen.bas

Opening a BFILE with OPEN

Opening a BFILE with OPEN

fread.bas

Reading data from a BFILE

Reading Data from a BFILE

freadprt.bas

Reading portion of a BFILE data using substr

Reading a Portion of BFILE Data Using SUBSTR

fupdate.bas

Updating a BFILE by initializing a BFILE locator

Updating a BFILE by Initializing a BFILE Locator

lappend.bas

Appending one LOB to another

Appending One LOB to Another

lcompare.bas

Comparing all or part of LOB

Comparing All or Part of Two LOBs

lcopy.bas

Copying all or part of a LOB to another LOB

Copying All or Part of One LOB to Another LOB

lcopyloc.bas

Copying a LOB locator

Copying All or Part of One LOB to Another LOB

ldisbuf.bas

Disabling LOB buffering (persistent LOBs)

Disabling LOB Buffering

ldisplay.bas

Displaying LOB data

Displaying LOB Data

lenbuf.bas

Enabling LOB buffering

Enabling LOB Buffering

lerase.bas

Erasing part of a LOB

Erasing Part of a LOB

linsert.bas

Inserting a row by initializing LOB locator bind variable

Inserting a Row by Initializing a LOB Locator Bind Variable

llength.bas

Getting the length of a LOB

Length: Determining the Length of a LOB

lloaddat.bas

Loading a LOB with BFILE data

Loading a LOB with Data from a BFILE

lread.bas

Reading data from LOB

Reading Data from a LOB

lsubstr.bas

Reading portion of LOB (substr)

Reading a Portion of a LOB (SUBSTR)

ltrim.bas

Trimming LOB data

Trimming LOB Data

lwrite.bas

Writing data to a LOB

Writing Data to a LOB


Java LOB Demonstration Files

The following table lists Java demonstration files. These files are installed in $ORACLE_HOME/rdbms/demo/lobs/java/.

Table A-4 Java Demonstration Examples

File Name Description Usage Information

Readme.txt

-

See the Chapter "Getting Started" in the "Oracle Database JDBC Developer's Guide and Reference" for information on setting up your system to be able to compile and run JDBC programs with the Oracle Driver

LobDemoConnectionFactory.java

-

As written LobDemoConnectionFactory uses the JDBC OCI driver with a local connection. You should edit the URL "jdbc:oracle:oci8:@" to match your setup. Again see the "Getting Started" section in the JDBC manual.

fclose_c.java

Closing a BFILE with CLOSE

Closing a BFILE with CLOSE

fclose_f.java

Closing a BFILE with FILECLOSE

Closing a BFILE with FILECLOSE

fclosea.java

Closing all open BFILEs

Closing All Open BFILEs with FILECLOSEALL

fcompare.java

Comparing all or parts of two BFILEs

Comparing All or Parts of Two BFILES

fexists.java

Checking if a BFILE exists

Determining Whether a BFILE Exists

ffilopen.java

Opening a BFILE with FILEOPEN

Opening a BFILE with FILEOPEN

ffisopen.java

Checking if the BFILE is OPEN with FILEISOPEN

Determining Whether a BFILE Is Open with FILEISOPEN

fgetdir.java

Getting the directory object name and filename of a BFILE

Getting Directory Object Name and File Name of a BFILE

finsert.java

Inserting row containing a BFILE by initializing a BFILE locator

Inserting a Row Containing a BFILE

fisopen.java

Checking if the BFILE is open with ISOPEN

Determining Whether a BFILE Is Open Using ISOPEN

flength.java

Getting the length of a BFILE

Getting the Length of a BFILE

fopen.java

Opening a BFILE with OPEN

Opening a BFILE with OPEN

fpattern.java

Checking if a pattern exists in a BFILE using instr

Checking If a Pattern Exists in a BFILE Using INSTR

fread.java

Reading data from a BFILE

Reading Data from a BFILE

fupdate.java

Updating a BFILE by initializing a BFILE locator

Updating a BFILE by Initializing a BFILE Locator

lappend.java

Appending one LOB to another

Appending One LOB to Another

lcompare.java

Comparing all or part of LOB

Comparing All or Part of Two LOBs

lcopy.java

Copying all or part of a LOB to another LOB

Copying All or Part of One LOB to Another LOB

lerase.java

Erasing part of a LOB

Erasing Part of a LOB

linsert.java

Inserting a row by initializing LOB locator bind variable

Inserting a Row by Initializing a LOB Locator Bind Variable

linstr.java

Seeing if pattern exists in LOB (instr)

Patterns: Checking for Patterns in a LOB Using INSTR

lisopen.java

Seeing if LOB is open

Determining Whether a LOB is Open

listempb.java

Seeing if LOB is temporary

Determining Whether a LOB instance Is Temporary

listempc.java

Seeing if LOB is temporary

Determining Whether a LOB instance Is Temporary

llength.java

Getting the length of a LOB

Length: Determining the Length of a LOB

lloaddat.java

Loading a LOB with BFILE data

Loading a LOB with Data from a BFILE

lread.java

Reading data from LOB

Reading Data from a LOB

lsubstr.java

Reading portion of LOB (substr)

Reading a Portion of a LOB (SUBSTR)

ltrim.java

Trimming LOB data

Trimming LOB Data

lwrite.java

Writing data to a LOB

Writing Data to a LOB

lwriteap.java

Writing to the end of LOB (write append)

Appending to a LOB