Database Reference
In-Depth Information
Figure 6-76.
Entering the report query with a BLOB column
Notice the change in the last column in the SQL statement. Using
dbms_lob.getlength
indicates to APEX whether the
ATTACHMENT
BLOB column contains any data. If it does, the query
returns a number greater than 0.
Now you need to alter the report column to display a link allowing
the end user to download any document that may have been uploaded:
6. Click the
Report Attributes
tab. Doing so saves all changes you just
made on the Region Definition tab.
7. Edit the
ATTACHMENT
column, and scroll to the
Column Attributes
section.
In order for the report column to recognize the fact that it's supposed
to be displayed as a BLOB, you must indicate that the format for the
field is a BLOB by entering the word
BLOB
in the Number/Date
Format field:
8. In the
Column Attributes
section, enter the word
BLOB
into the
Number/Date Format
field, and press
Tab
. The page refreshes, and the
Blob Column Attributes
section is now visible on the page.
9. In the
Blob Column Attributes
section, enter
TICKET_DETAILS
for
Blob
Table
,
for
Blob
Column
,
ATTACHMENT