Re: varchar_transform - Mailing list pgsql-hackers

From Robert Haas
Subject Re: varchar_transform
Date
Msg-id CA+TgmoZZmTQEX3OR6d7P5=_6obhYSnadps57zf9Rdz-T2jau8g@mail.gmail.com
Whole thread Raw
In response to varchar_transform  (Mohsen SM <mohsensoodkhah@gmail.com>)
List pgsql-hackers
On Mon, Feb 24, 2014 at 2:11 AM, Mohsen SM <mohsensoodkhah@gmail.com> wrote:
> when did use varchar_transform function?
> src/backend/uitls/adt/varchar.c.

The main point of that machinery is that if you do something like
ALTER TABLE zot ALTER COLUMN thunk SET DATA TYPE varchar(30) on a
column that is currently varchar(20), it won't feel obliged to rewrite
the table.  That function lets it figure out that anything that's a
valid varchar(20) value is also a valid varchar(30) value.

-- 
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company



pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: 9.5: UPDATE/DELETE .. ORDER BY .. LIMIT ..
Next
From: Peter Eisentraut
Date:
Subject: Re: [PATCH] Use MAP_HUGETLB where supported (v3)