Subject | Re: [IBO] elementary question, blob versus varchar in ib |
---|---|
Author | bullardjuk |
Post date | 2002-03-15T21:38:35Z |
--- In IBObjects@y..., Daniel Rail <daniel@a...> wrote:
wasting space for all this time? Why not have a varchar(255) if it
really takes no space in the database when null?
Yes I expect to use memo components to put such comments in.
I suppose I could do some experiment to test the fact that null
columns occupy no space but I have not seen that in the Interbase
manuals anywhere...perhaps I should know it anyway. I have always
been confused about varchar(20) versus char(20).
Any confirmation would be welcome.
Dave
>cant re-find it. Was it 24 chars ??blob
>
> For blobs, there's only a blob id that is stored and points to the
> itself when one is needed for the field. If I'm not mistaken theblob id
> is a 64bit integer. So, if no blob is defined for the record, thenthe
> only space taken up is 64bits. The only downside to using blobs isthat
> they are not searchable just using a SELECT statement, you mighthave to
> implement your own search methods or use a full text search engineas the
> one that Jason has. By giving a blob to your customer, you wont bebugged
> anymore to increase the comment field size.(100)
>
> On the other hand, increasing the field from varchar(40) to varchar
> isn't much of a deal. As mentioned before, the size stored in thedatabase
> is the same concept, but you will be transferring 100 charactersinstead of
> 40 characters to your application.then
>
> >To this has to be added programming complexity but if I have to
> >I will.you know
>
> To know what needs to be changed, if required is up to you. Since
> the code better than any of us. Definitely, if switching over to ablob,
> you might need to use a memo component to enter and view the text.Thanks for your help. Have I been worrying my poor old head about
>
>
> Daniel Rail
> Senior System Engineer
wasting space for all this time? Why not have a varchar(255) if it
really takes no space in the database when null?
Yes I expect to use memo components to put such comments in.
I suppose I could do some experiment to test the fact that null
columns occupy no space but I have not seen that in the Interbase
manuals anywhere...perhaps I should know it anyway. I have always
been confused about varchar(20) versus char(20).
Any confirmation would be welcome.
Dave