Re: Column Name Length - Mailing list pgsql-novice

From Ernesto Gutierrez
Subject Re: Column Name Length
Date
Msg-id 00ec01c20e77$97b0d200$2606000a@egutierrez
Whole thread Raw
In response to Column Name Length  ("James Kelty" <jamesk@ashlandagency.com>)
List pgsql-novice
I have to laugh because I ran into precisely this problem for the first time
earlier today.

It appears that the maximum limit to any identifier name (be it table,
column, sequence, etc) is equal to the NAMEDATALEN constant in
/src/include/postgres_ext.h. So, presumably you can recompile the binaries
for a larger value. 64 (rather than 32) has been discussed in various places
as a reasonable compromise between convenience and performance. However, I
haven't tried this as yet. Perhaps someone else has better advice.

Ernie Gutierrez
Walnut Creek, California

----- Original Message -----
From: "James Kelty"
> Hello,
>
> It seems that colummn name lengths are limited to 32 characters, is this
> true?  Actually 31 when I think about it. We have a column name that is 32
> characters long, but the last character is getting chopped of. Is there a
> way around this?
>
> -James
>
>
> James Kelty
> Sr. Unix Systems Administrator
> The Ashland Agency
> jamesk@ashlandagency.com
> 541.488.0801
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 6: Have you searched our list archives?
>
> http://archives.postgresql.org


pgsql-novice by date:

Previous
From: "James Kelty"
Date:
Subject: Column Name Length
Next
From: Tom Lane
Date:
Subject: Re: PQescapeString