Re: Truncation of object names

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Joel Burton <jburton(at)scw(dot)org>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Truncation of object names
Date: 2001-04-13 20:55:24
Message-ID: 7731.987195324@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Joel Burton <jburton(at)scw(dot)org> writes:
>> Have you thought about simply increasing NAMEDATALEN in your
>> installation? If you really are generating names that aren't unique
>> in 31 characters, that seems like the way to go ...

> Other than (a) it wastes a bit of space in the pg_ tables, and (b) it may
> screw up postgresql utility programs (pgaccess, pgadmin, etc.), is there
> any reason to keep the default at 32? Are there performance limitations?

Those are pretty much the reasons, plus a compatibility issue:
NAMEDATALEN *is* visible to clients (that's why it's in postgres_ext.h).
So changing the default value would risk breaking clients that hadn't
been recompiled.

> (Will C-based triggers and client programs and such need to be modified?)

Not if they've been properly coded (written in terms of NAMEDATALEN not
a hard constant).

Obviously, these objections are not strong enough to keep us from
increasing the standard value of NAMEDATALEN if it seems that many
people are running into the limit. But AFAICT relatively few people
have such problems, and I'm hesitant to make everyone deal with a change
for the benefit of a few. Count me as a weak vote for leaving it where
it is ...

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Nathan Myers 2001-04-13 20:59:29 Re: Truncation of object names
Previous Message Joel Burton 2001-04-13 20:33:09 Re: Truncation of object names