Search Postgresql Archives

Re: JOIN column maximum

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Lee Hachadoorian <lee.hachadoorian@xxxxxxxxx> writes:
> How is the number of columns in a join determined? When I combine somewhere
> around 90 tables in a JOIN, the query returns:

> ERROR: joins can have at most 32767 columns

It's the sum of the number of columns in the base tables.

> I'm sure most people will say "Why the hell are you joining 90 tables."

Not only that, but why are you working with over-300-column tables?
Seems like your schema design needs rethinking.

> I've asked this list before for advice on how to work with the
> approximately 23,000 column American Community Survey dataset,

Are there really 23000 populated values in each row?  I hesitate to
suggest an EAV approach, but it kinda seems like you need to go in that
direction.  You're never going to get decent performance out of a schema
that requires 100-way joins, even if you avoid bumping up against hard
limits.

			regards, tom lane

-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux