CLOB support in Jasper reports

By: Muralidhar bp - pmurli
CLOB support in Jasper reports
2003-01-17 03:35
Hello,

I have to develop a report, in which it consists of CLOB data. Please help me how to go with it.

Thanx
Murli




By: Teodor Danciu - teodord
RE: CLOB support in Jasper reports
2003-01-17 05:57

Hi,

Pure CLOB/BLOB support is not yet available
in JasperReports.

Not sure, but using InputStream report fields might help.

Thank you,
Teodor





By: Muralidhar bp - pmurli
RE: CLOB support in Jasper reports
2003-01-22 02:16
Hii,

How about if i write a store procedure to store the data in varchar2(32000), and pass the procedure in the query string.

Thanks
Murli
2002 JI Open Discussion's picture
Joined: Aug 10 2006 - 3:28am
Last seen: 17 years 1 month ago

3 Answers:

Hi
I am using iReport 1.2.2 as part of OSRMT v1.4. This version of iReport does not appear to support CLOBs? We instantiated OSRMT v1.4 with SQL Server Express using a separate jtsds-1.2.jar for the database connection driver. Has anyone written an extension to iReport to support the conversion of CLOBs to strings?

Thanks In Advance
jpb
brazyj's picture
71
Joined: Feb 12 2007 - 6:37am
Last seen: 16 years 7 months ago
brazyj wrote:
Hi
I am using iReport 1.2.2 as part of OSRMT v1.4. This version of iReport does not appear to support CLOBs? We instantiated OSRMT v1.4 with SQL Server Express using a separate jtsds-1.2.jar for the database connection driver. Has anyone written an extension to iReport to support the conversion of CLOBs to strings?

Thanks In Advance
jpb



In jasper reports 1.2.8 at least it returns the CLOB Columns as one long string. But, lets say you needed to process something from a CLOB anyways.

You could see what java object is returned form the CLOB column and write a small class that will take in as a parameter an object of that type. Then in there you extract the string from the CLOB and return a String object. Then in iReport place that class you coded in its classpath. Then in a Field expression call your class statically using its absolute package path (ie. mypackage.name.CLOBStringConverter.convertMyObj($F{TheCLOBColumn}))

K, don't know if this will work or not cos I only tried stuff like this on v1.2.8 of jasper/iReport to convert BLOBs to text (don't ask, some progs store stuff only in bytes).

Hope this helps.
DMA02's picture
296
Joined: Dec 7 2006 - 6:26pm
Last seen: 16 years 9 months ago
In the release notes for JasperReports version 1.3.1 I found:

"support for CLOB and BLOB report fields in JRResultSetDataSource"

Does this mean JasperReports now supports CLOB fields? I am in desperate need to display a CLOB field in a report. Can someone point me in the right direction on this?
sabernethy's picture
Joined: Sep 17 2006 - 9:22pm
Last seen: 2 years 3 weeks ago
Feedback
randomness