Subject Re: [ib-support] character sets and arrays and blobs
Author Geoff Worboys
> The documentation is wrong. dsql_describe returns a
> value for sqlsubtype on normal character fields that
> use a specific character set and collation. In the
> case below it was ISO8859_1 FR_FR.

Ouch! I did see some code in my browsing where characterset and
collation merged this way but did not follow it through. Thanks.

> When you open a blob, you set a structure called a bdb
> (blob descriptor block) to indicate the desired output
> type. InterBase automatically filters from the input
> to the output type. Some relevant code follows.

This only happens if you actually specify a bdb with source_interp and
target_interp character sets. If you dont specify then both are
defaulted to 0 (which corresponds to CS_NONE, not CS_DYNAMIC (127)).
Resulting in no filtering.

Even if the values defaulted to CS_DYNAMIC, the code in BLB_Open2
updates both source_interp and target_interp to the same (attachment
character set?) identity. Again resulting in no filtering.

So this seems to verify what I am seeing; unless the client actually
specifies that it wants character set filtering it will not be done -
unlike normal text fields which happens automatically.

> > > >Arrays...
> No, I was wrong. Same mechanism as above.

Same code to open the blob data, so same lack of filter definition -
and no apparent way to specify one even if such filters work with

Thanks for your help.

Geoff Worboys
Telesis Computing