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

(partial?) indexes, LIKE and NULL

From: "Marinos J(dot) Yannikos" <mjy(at)geizhals(dot)at>
To: pgsql-performance(at)postgresql(dot)org
Subject: (partial?) indexes, LIKE and NULL
Date: 2004-01-27 19:26:06
Message-ID: (view raw or whole thread)
Lists: pgsql-performance

with the following table:

     Table ""
  Column | Type | Modifiers
  t      | text |
      "a" btree (t)

Shouldn't queries that use
    ... where t like '%something%'

benefit from "a" when t is NULL in almost all cases, since the query 
planner could use "a" to access the few non-NULL rows quickly? It 
doesn't seem to work right now.

(I assume that it would make no difference if the index "a" was partial, 
excluding NULLs)



pgsql-performance by date

Next:From: Bill MoranDate: 2004-01-27 19:39:21
Subject: Re: On the performance of views
Previous:From: Joshua D. DrakeDate: 2004-01-27 18:52:21
Subject: pl/pgSQL versus pl/Python

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