You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ojb-user@db.apache.org by Andy Czerwonka <cz...@arcticpenguin.ca> on 2003/09/22 03:58:08 UTC
Evaluation and CLOB... or not
Hi guys/gals,
I've got a problem that I'd like to solve, and at the same time I'd like
to evaluate OJB as a potential solution moving forward in a project I'm
using. Anyway here' my issue.
I've got a simple socket listener that listens for message from an HL7
message server. The listener simple takes the message an throws it on a
queue, which is just a table in an Oracle database. There are a couple
of fields, but the important field is the actual message, which can
simple be represented in Java using a String. Saying that, the message
can be larger than 4K. The Oracle JDBC drivers seem to have a problem
with anything larger than 4k. So, here's my question:
I could break up the message and fire them into multiple records and
rebuild them on subsequent reads. Or, I could use a CLOB type and fire
the whole thing in. Now, initial tests tell me that using the CLOB on
anything > 4K is still troublesome. Does OJB deal with this? If not,
I'm guessing that I could still use OJB by breaking up the message in a
message class that'd look something like this:
class Message
{
BigDecimal id;
Message child;
Message parent
String value;
int status;
}
The table would simple have a unique sequence id, the CLOB or VARCHAR
message, and parent and child foreign keys. I'm guessing that this is a
simple map for OJB? Does anyone see any limitations?
One thing I don't quite understand is how to deal with the id using
sequences using OJB. Is there anything special I'd need to do?
--
-andy
---------------------------------------------------------------------
To unsubscribe, e-mail: ojb-user-unsubscribe@db.apache.org
For additional commands, e-mail: ojb-user-help@db.apache.org