Subject RE: [IBO] Invalid Blob ID's with IBOQuery
Author IBO Support List
Sub-type 1 means text.
Sub-type 0 means binary.

If you wish to store binary data in a blob, do not use sub-type 1. If IBO
allowed this in the past, it was not intentional on my part.

Jason

-----Original Message-----
From: IBObjects@yahoogroups.com [mailto:IBObjects@yahoogroups.com] On Behalf
Of pb.software
Sent: 08 March 2012 10:12 AM
To: IBObjects@yahoogroups.com
Subject: [IBO] Invalid Blob ID's with IBOQuery

There is a problem with the TIBOQuery and blob fields. I have spend two days
dealing with this problem at all levels until I finally discovered the
problem.

I dont understand why a blob field declared as "BLOB SUB_TYPE 1 SEGMENT SIZE
80 CHARACTER SET NONE COLLATE NONE" is created in IBO as a widememo field.
It should be created as a TBlobFiled with blobtype of ftwidememo but better
yet just a plain ftblobtype which can read any blob format.

If I declare a blob field as "BLOB SUB_TYPE 0 SEGMENT SIZE 80" to save
binary files, pictures, etc. I can still save text in it and display it. I
have never had problems with a plain ftblob type field. This was not the
behavior of IBO before, more specific TIBO Class.

The ftwidememo implementation is not very compatible with some components
which will throw an invalid BLOB ID saving a text memo into a blob field of
"BLOB SUB_TYPE 1 SEGMENT SIZE 80 CHARACTER SET NONE COLLATE NONE" while as I
discovered after two days if I change the field type manually or create the
in code as:

qFilesFILE_COMMENTS := TBlobField.Create(Self);

It works as expected. Can someone shed some light on this and why are
persistent fields being created as widememo instead of regular ftblob?

Thanks in advance, Pedro.