Subject Re[2]: [firebird-support] Calcurate row size
Author Listeny
Thank you very much Helen,

Just one more question.
One varchar column -- which has NULL value -- spends only 2 bytes in that row,
Is this correct ?


On Tue, 13 Jul 2004 17:10:12 +1000
Helen Borrie <helebor@...> wrote:

> At 02:13 PM 13/07/2004 +0900, you wrote:
> >Hi,
> >
> > Would someone tell me resources/documents of 'how to calculate number of
> >bytes on each row' for FB1.5 ?
>
> If you have most of your fingers and toes, you can do it without a calculator.
>
> Smallint are 2 bytes, Integers 4, BigInt 8. Numeric and decimal 2, 4 or 8
> depending on precision. Float 4, double precision 8.
>
> Char = exact number of bytes as defined (No. of characters * character byte
> size)
> Varchar, exact number of bytes + 2.
>
> Timestamp 8 bytes
> Date 4 bytes (dialect 3) or 8 bytes (dialect 1)
> Time 4 bytes
>
> Blobs and arrays aren't stored with the row. Allow 4 bytes per blob_id.
>
> Plus, for each row, 2 bytes to store the db_key and the row offset (or is
> it 4 bytes?)
>
> /heLen
>
>
>
>
>
> Yahoo! Groups Links
>
>
>
>
>