Path: csiph.com!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder1.hal-mli.net!news.netfront.net!reversiblemaps.ath.cx!not-for-mail From: Jasen Betts Newsgroups: comp.databases.postgresql Subject: Re: index on a partitioned table Date: 18 Aug 2012 00:30:17 GMT Organization: Dis (not Dat) Organisation Lines: 27 Message-ID: References: NNTP-Posting-Host: 118.90.84.119 Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Trace: adenine.netfront.net 1345249831 77455 118.90.84.119 (18 Aug 2012 00:30:31 GMT) X-Complaints-To: news@netfront.net NNTP-Posting-Date: Sat, 18 Aug 2012 00:30:31 +0000 (UTC) X-Face: ?)Aw4rXwN5u0~$nqKj`xPz>xHCwgi^q+^?Ri*+R(&uv2=E1Q0Zk(>h!~o2ID@6{uf8s;a +M[5[U[QT7xFN%^gR"=tuJw%TXXR'Fp~W;(T"1(739R%m0Yyyv*gkGoPA.$b,D.w:z+<'"=-lVT?6 {T?=R^:W5g|E2#EhjKCa+nt":4b}dU7GYB*HBxn&Td$@f%.kl^:7X8rQWd[NTc"P"u6nkisze/Q;8 "9Z{peQF,w)7UjV$c|RO/mQW/NMgWfr5*$-Z%u46"/00mx-,\R'fLPe.)^ User-Agent: slrn/pre1.0.0-18 (Linux) Xref: csiph.com comp.databases.postgresql:408 On 2012-08-16, Greg Hennessy wrote: > I am using postgresql 8.1.3 on redhat, Upgrade! But seriously, upgrade. 8.1.23 at a minumum. > and trying to use partitioned > tables to manage a multi-terabyte table. I've created the parent table > and the child tables. > > If I want to add an index, does it matter if I index the parent or the > collection of children? I can't find a discussion of the pros or cons > on this in the documentation. you need to add it to each of the children that will benefit from having it. usually this means all of them. indexing the parent will bave no possitive effect, the database knows it's really empty you're going to want to turn constraint excluusion "on" if you haven't alredy. (8.1 doesn't have a 'partition' setting for constraint exclusiin) upgrade to someting newer like 9.1 for improved performance. -- ⚂⚃ 100% natural --- Posted via news://freenews.netfront.net/ - Complaints to news@netfront.net ---