• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Insert CLOB data upto 2 GB data

 
Greenhorn
Posts: 16
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I need to store huge data (which is a xml data) in a CLOB datatype which is running on JBoss server.Iam successful in writing the code but my code has a big limitation that it can store upto 32523 (approx) characters.But,my application will be receiving the xml's of upto 2 GB (Approximately). But,iam unable to find the alternate for this.



When iam using to create CLOB object directly,it is giving Class Cast exception,thats the reason, i have tried using the above code.

I have tried to create clob in the following way which is giving Class cast exception.




Hence i tried using WrappedConnection of JBoss

But still throwing class cast exception.
Did anyone had this kind of issue/problem of storing more than 2 GB data into CLOB datatype?Is there any another alternate for this?
Please let me know

Thanks in advance.
 
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
How about storing the monster data as a file with a unique name and putting the name in the database?

Bill
 
Vamsi bhujanga
Greenhorn
Posts: 16
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
We cant save it in the form of a file as we have many challenges in using it.
Is there any other alternate?
 
Rancher
Posts: 43081
77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
What kinds of challenges? Storing it in the DB will present substantial challenges as well (larger challenges probably than using the file system).
 
author
Posts: 3285
13
Mac OS X Eclipse IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Adding a "Me too!"

We have a similar problem to this and storing a handle to the file and using a file system to store the actual file is definitely the way to go, for all sorts of performance reasons etc.
 
William Brogden
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
As I understand it, the underlying mechanism by which DBs store large Blob and Clob objects is in fact by writing a file and only storing the file location in the DB tables.

Bill
 
reply
    Bookmark Topic Watch Topic
  • New Topic