
September 28th, 2011, 05:51 AM
|
|
Registered User
|
|
Join Date: Sep 2011
Posts: 5
Time spent in forums: 2 h 14 m 10 sec
Reputation Power: 0
|
|
|
Get Data from CLOB
Hey All,
I'm writing a PHP page to display some data from an Oracle database. Unfortunately, I can't copy the code because it's proprietary, but I'm having an issue I was hoping somebody could help me with. One of the columns in the db is of type CLOB. I'm having trouble getting the data from the CLOB column.
The way the code is now, is there is a query string read into a variable, and the query string variable is read into a function that then retrieves the data from the db. Once the result set is returned, it is parsed to get data from all of the columns. The issue is that I've never worked with CLOB data before, so I'm having some difficulty extracting the data for that column. I know I can use the DBMS_LOB.READ function, but I'm not sure how to apply it in this case. The following is a generic form of the query string I'm using with b.clob_col being the column I'm having issues with.
$queryString = <<<EOD
SELECT a.col1,
a.col2,
a.col3,
b.col4,
b.col5,
b.clob_col,
from table1 b
inner join b.col4
on blah1
inner join a.col2
on blah2
where blah
and blah
EOD;
Any help is appreciated!!
|