Re: create index on function - why?

From: "Nick Fankhauser" <nickf(at)ontko(dot)com>
To: <wweng(at)kencast(dot)com>, <pgsql-sql(at)postgresql(dot)org>
Subject: Re: create index on function - why?
Date: 2002-02-15 16:33:41
Message-ID: NEBBLAAHGLEEPCGOBHDGIELJEFAA.nickf@ontko.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

I don't know yet if it will help me. (I was doing empirical research when I
ran into my problem.) My reasoning went like this:

Since using a function in my "where" clause forces postgresql to do a table
scan instead of using my index on the field, I was hoping to build an index
on the function, which *would* get used. I'm pretty sure this will work, but
I'll post my results to the list if I find that it doesn't work.

-Nick

> -----Original Message-----
> From: pgsql-sql-owner(at)postgresql(dot)org
> [mailto:pgsql-sql-owner(at)postgresql(dot)org]On Behalf Of Wei Weng
> Sent: Friday, February 15, 2002 11:26 AM
> To: pgsql-sql(at)postgresql(dot)org
> Subject: [SQL] create index on function - why?
>
>
> I can understand the rationale behind creating index on tables, it
> speeds up the searching.
>
> But what is the rationale behind creating index on a function? how does
> it help with the database performance?
>
> Thank you.
>
> --
> Wei Weng
> Network Software Engineer
> KenCast Inc.
>
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo(at)postgresql(dot)org
>

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Tom Lane 2002-02-15 16:46:46 Re: create index on function - why?
Previous Message Nick Fankhauser 2002-02-15 16:27:57 Re: creating an index on a function