Re: [HACKERS] Re: varchar() troubles (fwd)

From: "Thomas G(dot) Lockhart" <lockhart(at)alumni(dot)caltech(dot)edu>
To: Bruce Momjian <maillist(at)candle(dot)pha(dot)pa(dot)us>
Cc: "Vadim B(dot) Mikheev" <vadim(at)sable(dot)krasnoyarsk(dot)su>, PostgreSQL-development <hackers(at)postgresql(dot)org>
Subject: Re: [HACKERS] Re: varchar() troubles (fwd)
Date: 1998-01-16 05:26:08
Message-ID: 34BEEF70.F9AC0094@alumni.caltech.edu
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

> OK, here is a temporary fix to the problem. It does the heap_open(),
> then replaces the attrs for VARCHAR with attlen of -1. You can't just
> change the field, because the data is in a cache and you are just
> returned a pointer.
>
> Can I add an 'attdeflen' for "attributed defined length" field to
> pg_attribute, and change the attlen references needed to the new field?
> This is the only proper way to fix it.

Bruce, does your "temporary fix" seem to repair all known problems with varchar()? If so, would you be interested in
holding off on a "proper fix" and coming back to it after v6.3 is released? At that time, we can try solving the general
problem of retaining column-specific attributes, such as your max len for varchar, declared dimensions for arrays, and
numeric() and decimal() types. Or, if you have time to try a solution now _and_ come back to it later...

- Tom

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Darrell A. Escola 1998-01-16 05:32:05 Re: [HACKERS] Cannot build recent snapshot
Previous Message Bruce Momjian 1998-01-16 05:05:03 Re: [HACKERS] Re: varchar() troubles (fwd)