X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by postgresql.org (Postfix) with ESMTP id 27A129DC80D for ; Tue, 21 Feb 2006 11:32:08 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 91231-05 for ; Tue, 21 Feb 2006 11:32:11 -0400 (AST) X-Greylist: domain auto-whitelisted by SQLgrey- Received: from zproxy.gmail.com (zproxy.gmail.com [64.233.162.195]) by postgresql.org (Postfix) with ESMTP id 468F79DC86D for ; Tue, 21 Feb 2006 11:32:03 -0400 (AST) Received: by zproxy.gmail.com with SMTP id 18so1253420nzp for ; Tue, 21 Feb 2006 07:32:08 -0800 (PST) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:references; b=emq/KFb2HPpc4htIMJCpA5J8nypz2+v8k9/IhF77fnqhbLQkIODr4c1GXFUykeFlNWfK/ktVqjTjSp8GwsyTiGGR2+F7OUI854ti8qv/Io9XjjrFTrxQCg5l4ToJ00gZAO8pyIioilX9FKRYmfoCfheqQ351ns/SrG/ZChv7ALk= Received: by 10.36.41.4 with SMTP id o4mr4555102nzo; Tue, 21 Feb 2006 07:32:07 -0800 (PST) Received: by 10.36.106.12 with HTTP; Tue, 21 Feb 2006 07:32:07 -0800 (PST) Message-ID: Date: Tue, 21 Feb 2006 17:32:07 +0200 From: "Ibrahim Tekin" To: "Stefan Schwarzer" Subject: Re: Avoid querying a specific field - how? Cc: pgsql-sql@postgresql.org In-Reply-To: MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_22210_6038593.1140535927711" References: X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=0.756 required=5 tests=[AWL=0.755, HTML_MESSAGE=0.001] X-Spam-Score: 0.756 X-Spam-Level: X-Archive-Number: 200602/255 X-Sequence-Number: 24265 ------=_Part_22210_6038593.1140535927711 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline i may i misunderstood your question but it seems to me, partial indexes wil= l work for you. check this example: http://www.postgresql.org/docs/8.1/interactive/indexes-partial.html#INDEXES= -PARTIAL-EX2 On 2/21/06, Stefan Schwarzer wrote: > > Hi, > > does anyone know how to build a query that SELECTs all fields but not > a specific one? I have a couple of tables, holding statistical > information as well as the geospatial one (via Postgis). When I query > the table I'd like to query only the statistical part - not the > geospatial, which is not necessary and slows done incredibly the > query. I searched a bit within the Postgres SQL domain. It seems > there is an EXCEPT statement, but it seems that it works differently... > > Thanks for any help, > > Stef > > ---------------------------(end of broadcast)--------------------------- > TIP 1: if posting/reading through Usenet, please send an appropriate > subscribe-nomail command to majordomo@postgresql.org so that your > message can get through to the mailing list cleanly > ------=_Part_22210_6038593.1140535927711 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline i may i misunderstood your question but it seems to me, partial indexes wil= l work for you.
check this example: http://www.= postgresql.org/docs/8.1/interactive/indexes-partial.html#INDEXES-PARTIAL-EX= 2

On 2/21/06, Stefan Schwarzer <stefan.schwarzer@grid.unep.ch> wrote:
Hi,

does anyone know how to build a query that SELECTs all fields bu= t not
a specific one? I have a couple of tables, holding statistical
= information as well as the geospatial one (via Postgis). When I query
the table I'd like to query only the statistical part - not the
geospati= al, which is not necessary and slows done incredibly the
query. I search= ed a bit within the Postgres SQL domain. It seems
there is an EXCEPT sta= tement, but it seems that it works differently...

Thanks for any help,

Stef

---------------------------= (end of broadcast)---------------------------
TIP 1: if posting/reading = through Usenet, please send an appropriate
     = ;  subscribe-nomail command to=20 majordomo@postgresql.org so= that your
       message can get through = to the mailing list cleanly

------=_Part_22210_6038593.1140535927711--