Re: Error with Clob

Fred Toussi <[email protected]>
Newsgroups gmane.comp.java.hsqldb.user
Message-ID <1363899713.17431.140661207498285.0341ED82@webmail.messagingengine.com>
If your data is 200 000 characters or larger per item, then you should
use CLOB. There is also a database option to translate LONGVARCHAR to
CLOB, but it's easier to specify clob directly. For example:

CREATE TABLE T (ID INT PRIMARY KEY, DATA CLOB(16M)

The above means a clob up to 16 MB can be stored. It allocates space
only according to the size of the actual data. For example if a data
item is 128 000 characters, it assigns 256 KB.

You could use LONGVARCHAR for your data and it also allocates space as
needed , but it will slow down your app.

The latest snapshot jars for version 2.3.0 also support clob compression
for storage. The final version will be released next month.

Fred


On Thu, Mar 21, 2013, at 20:43, Tmo_hsqldb_q wrote:
> Hi Fred,
> 
> We now have requirements to handle payloads larger than what
> varchar(1000)
> hold.  1 Megabyte to be exact.  I tried using longvarchar specifying no
> character size limit and it works in handling large payloads.  My only
> concern is the 16Megabyte allocation that the HSQLDB Documentation says
> it
> will assign.  Does it assign 16 megabytes for every row or a smaller
> amount
> initially?  We handle on avg smaller payloads 200,000 characters in size,
> but it can go up to 1Megabyte.
> 
> many thanks,
> Tony
> 
> 
> 
> --
> View this message in context:
> http://hsqldb.10974.n7.nabble.com/Error-with-Clob-tp151p3856.html
> Sent from the HSQLDB - User mailing list archive at Nabble.com.
> 
> ------------------------------------------------------------------------------
> Everyone hates slow websites. So do we.
> Make your web apps faster with AppDynamics
> Download AppDynamics Lite for free today:
> http://p.sf.net/sfu/appdyn_d2d_mar
> _______________________________________________
> Hsqldb-user mailing list
> Hsqldb-user@lists">[email protected]
> https://lists.sourceforge.net/lists/listinfo/hsqldb-user">hsqldb-user

------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_d2d_mar
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.