| From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
|---|---|
| To: | "Brian Hirt" <bhirt(at)mobygames(dot)com> |
| Cc: | "Postgres Hackers" <pgsql-hackers(at)postgresql(dot)org>, "Brian A Hirt" <bhirt(at)berkhirt(dot)com> |
| Subject: | Re: problems with table corruption continued |
| Date: | 2001-12-18 19:20:00 |
| Message-ID: | 17805.1008703200@sss.pgh.pa.us |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
"Brian Hirt" <bhirt(at)mobygames(dot)com> writes:
> I was trying to avoid adding additional computed fields to the tables and
> maintaining them with triggers, indexing and searching on them. The index
> function seemed like an elegant solution to the problem
Understood, but can you write the index function in a way that avoids
having it do a SELECT to get at data that it hasn't been passed? I'm
wondering if you can't define the function as just
f(first_name, last_name) = upper(first_name || ' ' || last_name)
and create the index on f(first_name, last_name). You haven't shown us
the queries you expect the index to be helpful for, so maybe this is not
workable...
regards, tom lane
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Mikheev, Vadim | 2001-12-18 19:25:08 | Re: problems with table corruption continued |
| Previous Message | Mike Mascari | 2001-12-18 19:13:15 | Re: Concerns about this release |