X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 5B9F9D9690 for ; Mon, 26 Sep 2005 01:31:17 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 56492-03 for ; Mon, 26 Sep 2005 04:31:15 +0000 (GMT) Received: from news.hub.org (news.hub.org [200.46.204.72]) by svr1.postgresql.org (Postfix) with ESMTP id B1A56D9699 for ; Mon, 26 Sep 2005 01:31:15 -0300 (ADT) Received: from news.hub.org (news.hub.org [200.46.204.72]) by news.hub.org (8.13.1/8.13.1) with ESMTP id j8Q4VFLg057350 for ; Mon, 26 Sep 2005 04:31:15 GMT (envelope-from news@news.hub.org) Received: (from news@localhost) by news.hub.org (8.13.1/8.13.1/Submit) id j8Q446wI051663 for pgsql-admin@postgresql.org; Mon, 26 Sep 2005 04:04:06 GMT (envelope-from news) From: Chris Browne X-Newsgroups: pgsql.admin Subject: Re: Performance question: Restore + INDEX Date: Sun, 25 Sep 2005 23:43:54 -0400 Organization: cbbrowne Computing Inc Lines: 24 Message-ID: <6064somr2d.fsf@dba2.int.libertyrms.com> References: <4337413D.4040802@mediaroot.de> Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 X-Complaints-To: usenet@news.hub.org User-Agent: Gnus/5.1007 (Gnus v5.10.7) XEmacs/21.4.17 (Jumbo Shrimp, linux) Cancel-Lock: sha1:S+EcfFJtmE5+tZLDYx9wZ5rP1RY= To: pgsql-admin@postgresql.org X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=-2.478 required=5 tests=[ALL_TRUSTED=-2.82, AWL=0.342] X-Spam-Level: X-Archive-Number: 200509/287 X-Sequence-Number: 19024 an@mediaroot.de (Aldor) writes: > I'm curious how other people do it: > > What is faster? > > 1. CREATE TABLE > 2. restore data > 3. CREATE INDEX > > or > > 1. CREATE TABLE > 2. CREATE INDEX > 3. restore data Creating the index AFTER loading the data is definitely faster. But by all means do your own tests; it's pretty easy to do so and satisfy yourself... -- (format nil "~S@~S" "cbbrowne" "ntlug.org") http://cbbrowne.com/info/languages.html "It worked about as well as sticking a blender in the middle of a lime plantation and hoping they'll make margaritas out of themselves." -- Frederick J. Polsky v1.0