Skip site navigation (1) Skip section navigation (2)

Re: Using index for IS NULL query

From: "Vladimir Sitnikov" <sitnikov(dot)vladimir(at)gmail(dot)com>
To: "Tomas Vondra" <tv(at)fuzzy(dot)cz>
Cc: Andrus <kobruleht2(at)hot(dot)ee>, pgsql-performance(at)postgresql(dot)org
Subject: Re: Using index for IS NULL query
Date: 2008-11-11 23:00:13
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-performance
> Yes, NULL values are not stored in the index, but you may create functional
> index on
Are you sure NULL values are not stored? btree, gist and bitmap index and
search for NULL values.

select amname, amindexnulls, amsearchnulls from pg_am;

 amname | amindexnulls | amsearchnulls
 btree  | t            | t
 hash   | f            | f
 gist   | t            | t
 gin    | f            | f
 bitmap | t            | t
(5 rows)

Sincerely yours,
Vladimir Sitnikov

In response to


pgsql-performance by date

Next:From: Scott MarloweDate: 2008-11-11 23:34:42
Subject: Re: Using index for IS NULL query
Previous:From: Jim 'Decibel!' NasbyDate: 2008-11-11 22:42:57
Subject: Re: Oddity with view (now with test case)

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group