OSDN Git Service

Defend against JOINs having more than 32K columns altogether. We cannot
authorTom Lane <tgl@sss.pgh.pa.us>
Sat, 5 Apr 2008 01:58:20 +0000 (01:58 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Sat, 5 Apr 2008 01:58:20 +0000 (01:58 +0000)
commitceb5db69d4fbbd327a2ae2d589069008bbe57bb6
tree31688c2cbdf620bfd1feb7c8434dd35a21d8f8a2
parent2a1cf97c22933368c8747711da0f30c35f4bddcd
Defend against JOINs having more than 32K columns altogether.  We cannot
currently support this because we must be able to build Vars referencing
join columns, and varattno is only 16 bits wide.  Perhaps this should be
improved in future, but considering that it never came up before, I'm not
sure the problem is worth much effort.  Per bug #4070 from Marcello
Ceschia.

The problem seems largely academic in 8.0 and 7.4, because they have
(different) O(N^2) performance issues with such wide joins, but
back-patch all the way anyway.
src/backend/parser/parse_relation.c
src/include/access/attnum.h