On 19/12/05, Daniel John Debrunner <[EMAIL PROTECTED]> wrote:

> The use I was suggesting CLOB for was the storage for mail recipents
> which currently is a LONG VARCHAR, not the body of the message.

Oh, my mistake.

> Though I was surprised to see BLOB for mail body storage, I'd naively
> assumed it would be CLOB.

Yeah, I thought you would, hence I jumped to the wrong conclusion!

> For the reasons you give BLOB is probably the
> correct storage, from the javax.mail classes it seems that the body is
> transported as a set of bytes.

Yeah, mail involves a lot of layers (defined largely in MIME specs) of
encoding to transport rich "modern" content on a protocol which dates
back to the days when US-ASCII was the only charater set there was.
You could say that MIME effectively specifies a binary "file format"
for any old thing, which is alos backwards compatible with ASCII
screen readers. It s also future proofed against bizarre new content
types and IMHO is an unsung triumph of the kind of big brain thinking
that made the net great.
Back to the subject at hand though, the safe way not to break the
encodings during transport is to ignore the whole issue and treat it
as bytes.

> Just FYI for Derby CLOBs, the character set is always Unicode and the
> stream is available through the standard ResultSet/Clob methods as a
> Java Reader or (not very useful) Ascii stream.

Sounds safe enough, but for simplicity I'd still rather just duck the
issue and stick with the bytes :-)

d.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to