> Huh, I don't know where I got the idea you were (or someone else was?) > in the position that attislocal should be reset.  I'll clean everything > up and submit the patch I had originally made.
> Huh, I don't know where I got the idea you were (or someone else was?)
> in the position that attislocal should be reset.  I'll clean everything
> up and submit the patch I had originally made.

All right, this is it.  This patch merely checks if child tables have
the column.  If atttypid and atttypmod are the same, the attributes'
attinhcount is incremented; else the operation is aborted.  If child
tables don't have the column, recursively add it.

attislocal is not touched in any case.

Alvaro Herrera

0x0FFF/gpdb,xuegang/gpdb,kaknikhil/gpdb,ahachete/gpdb,ahachete/gpdb,kaknikhil/gpdb,zaksoup/gpdb,Quikling/gpdb,Chibin/gpdb,rubikloud/gpdb,0x0FFF/gpdb,Postgres-XL/Postgres-XL,randomtask1155/gpdb,randomtask1155/gpdb,lpetrov-pivotal/gpdb,pavanvd/postgres-xl,pavanvd/postgres-xl,arcivanov/postgres-xl,rvs/gpdb,xuegang/gpdb,Chibin/gpdb,lpetrov-pivotal/gpdb,ahachete/gpdb,lintzc/gpdb,Quikling/gpdb,CraigHarris/gpdb,yuanzhao/gpdb,techdragon/Postgres-XL,adam8157/gpdb,edespino/gpdb,Quikling/gpdb,zeroae/postgres-xl,greenplum-db/gpdb,tangp3/gpdb,kmjungersen/PostgresXL,chrishajas/gpdb,postmind-net/postgres-xl,tangp3/gpdb,randomtask1155/gpdb,zaksoup/gpdb,kaknikhil/gpdb,royc1/gpdb,rvs/gpdb,jmcatamney/gpdb,ashwinstar/gpdb,zaksoup/gpdb,chrishajas/gpdb,snaga/postgres-xl,kmjungersen/PostgresXL,50wu/gpdb,CraigHarris/gpdb,Chibin/gpdb,xinzweb/gpdb,cjcjameson/gpdb,xuegang/gpdb,yuanzhao/gpdb,lintzc/gpdb,pavanvd/postgres-xl,50wu/gpdb,chrishajas/gpdb,atris/gpdb,0x0FFF/gpdb,xinzweb/gpdb,chrishajas/gpdb,edespino/gpdb,ashwinstar/gpdb,janebeckman/gpdb,snaga/postgres-xl,cjcjameson/gpdb,lpetrov-pivotal/gpdb,janebeckman/gpdb,ovr/postgres-xl,rubikloud/gpdb,jmcatamney/gpdb,oberstet/postgres-xl,lisakowen/gpdb,yazun/postgres-xl,cjcjameson/gpdb,arcivanov/postgres-xl,xinzweb/gpdb,adam8157/gpdb,jmcatamney/gpdb,Quikling/gpdb,oberstet/postgres-xl,janebeckman/gpdb,xuegang/gpdb,randomtask1155/gpdb,kmjungersen/PostgresXL,tangp3/gpdb,greenplum-db/gpdb,edespino/gpdb,ovr/postgres-xl,edespino/gpdb,royc1/gpdb,yuanzhao/gpdb,edespino/gpdb,rubikloud/gpdb,CraigHarris/gpdb,ovr/postgres-xl,lisakowen/gpdb,tangp3/gpdb,50wu/gpdb,Quikling/gpdb,royc1/gpdb,rvs/gpdb,postmind-net/postgres-xl,kmjungersen/PostgresXL,rubikloud/gpdb,zeroae/postgres-xl,cjcjameson/gpdb,tangp3/gpdb,xinzweb/gpdb,tpostgres-projects/tPostgres,Quikling/gpdb,foyzur/gpdb,rvs/gpdb,Quikling/gpdb,techdragon/Postgres-XL,kaknikhil/gpdb,janebeckman/gpdb,lpetrov-pivotal/gpdb,xuegang/gpdb,Chibin/gpdb,0x0FFF/gpdb,kaknikhil/gpdb,cjcjameson/gpdb,yazun/postgres-xl,yazun/postgres-xl,rvs/gpdb,lintzc/gpdb,adam8157/gpdb,zaksoup/gpdb,foyzur/gpdb,yazun/postgres-xl,atris/gpdb,snaga/postgres-xl,janebeckman/gpdb,Chibin/gpdb,royc1/gpdb,atris/gpdb,lpetrov-pivotal/gpdb,lintzc/gpdb,greenplum-db/gpdb,adam8157/gpdb,tpostgres-projects/tPostgres,foyzur/gpdb,zeroae/postgres-xl,arcivanov/postgres-xl,jmcatamney/gpdb,lpetrov-pivotal/gpdb,lisakowen/gpdb,rvs/gpdb,edespino/gpdb,techdragon/Postgres-XL,edespino/gpdb,chrishajas/gpdb,janebeckman/gpdb,yuanzhao/gpdb,ahachete/gpdb,randomtask1155/gpdb,lintzc/gpdb,lintzc/gpdb,Chibin/gpdb,kmjungersen/PostgresXL,foyzur/gpdb,50wu/gpdb,kaknikhil/gpdb,edespino/gpdb,janebeckman/gpdb,atris/gpdb,atris/gpdb,ashwinstar/gpdb,cjcjameson/gpdb,snaga/postgres-xl,rubikloud/gpdb,zaksoup/gpdb,greenplum-db/gpdb,CraigHarris/gpdb,postmind-net/postgres-xl,arcivanov/postgres-xl,yazun/postgres-xl,lisakowen/gpdb,atris/gpdb,Chibin/gpdb,royc1/gpdb,cjcjameson/gpdb,yuanzhao/gpdb,edespino/gpdb,oberstet/postgres-xl,foyzur/gpdb,jmcatamney/gpdb,xuegang/gpdb,jmcatamney/gpdb,0x0FFF/gpdb,0x0FFF/gpdb,tpostgres-projects/tPostgres,ahachete/gpdb,lisakowen/gpdb,tangp3/gpdb,zaksoup/gpdb,greenplum-db/gpdb,ahachete/gpdb,postmind-net/postgres-xl,ovr/postgres-xl,ahachete/gpdb,zaksoup/gpdb,ashwinstar/gpdb,chrishajas/gpdb,kaknikhil/gpdb,ashwinstar/gpdb,rubikloud/gpdb,ashwinstar/gpdb,cjcjameson/gpdb,adam8157/gpdb,ashwinstar/gpdb,techdragon/Postgres-XL,lisakowen/gpdb,yuanzhao/gpdb,lpetrov-pivotal/gpdb,adam8157/gpdb,Postgres-XL/Postgres-XL,greenplum-db/gpdb,adam8157/gpdb,jmcatamney/gpdb,royc1/gpdb,janebeckman/gpdb,pavanvd/postgres-xl,yuanzhao/gpdb,oberstet/postgres-xl,50wu/gpdb,CraigHarris/gpdb,kaknikhil/gpdb,zeroae/postgres-xl,jmcatamney/gpdb,edespino/gpdb,xuegang/gpdb,yuanzhao/gpdb,royc1/gpdb,lintzc/gpdb,randomtask1155/gpdb,greenplum-db/gpdb,tangp3/gpdb,Quikling/gpdb,xinzweb/gpdb,rvs/gpdb,50wu/gpdb,50wu/gpdb,CraigHarris/gpdb,lisakowen/gpdb,snaga/postgres-xl,CraigHarris/gpdb,arcivanov/postgres-xl,atris/gpdb,xuegang/gpdb,chrishajas/gpdb,lintzc/gpdb,Chibin/gpdb,foyzur/gpdb,rvs/gpdb,xinzweb/gpdb,chrishajas/gpdb,kaknikhil/gpdb,adam8157/gpdb,ahachete/gpdb,rubikloud/gpdb,xinzweb/gpdb,zeroae/postgres-xl,CraigHarris/gpdb,postmind-net/postgres-xl,Postgres-XL/Postgres-XL,tpostgres-projects/tPostgres,lisakowen/gpdb,50wu/gpdb,rubikloud/gpdb,janebeckman/gpdb,tpostgres-projects/tPostgres,ashwinstar/gpdb,pavanvd/postgres-xl,Postgres-XL/Postgres-XL,oberstet/postgres-xl,cjcjameson/gpdb,lpetrov-pivotal/gpdb,Quikling/gpdb,CraigHarris/gpdb,xuegang/gpdb,cjcjameson/gpdb,arcivanov/postgres-xl,Quikling/gpdb,zaksoup/gpdb,0x0FFF/gpdb,janebeckman/gpdb,foyzur/gpdb,ovr/postgres-xl,randomtask1155/gpdb,atris/gpdb,greenplum-db/gpdb,yuanzhao/gpdb,foyzur/gpdb,rvs/gpdb,techdragon/Postgres-XL,randomtask1155/gpdb,kaknikhil/gpdb,royc1/gpdb,lintzc/gpdb,tangp3/gpdb,rvs/gpdb,xinzweb/gpdb,Chibin/gpdb,Postgres-XL/Postgres-XL,yuanzhao/gpdb,0x0FFF/gpdb,Chibin/gpdb