pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
creating functional index over multiple columns
3+ messages / 3 participants
[nested] [flat]

* creating functional index over multiple columns
@ 2002-06-28 11:13 Chantal Ackermann <chantal.ackermann@biomax.de>
  2002-06-29 04:19 ` Re: creating functional index over multiple columns Christopher Kings-Lynne <chriskl@familyhealth.com.au>
  0 siblings, 1 reply; 3+ messages in thread

From: Chantal Ackermann @ 2002-06-28 11:13 UTC (permalink / raw)
  To: pgsql-sql

hello all,

I am new to this list, and I hope my request is well placed, here. I 
tried searching the archives but I wasn't lucky.

I want to create an index over two columns and one function:

the WHERE clause is:
WHERE lower(name)=? AND type_id=? AND syn_id=?

I know from the docs that I have to create on function that wraps these 
three values for creating the appropriate index. I have practically no 
idea how to do this (e.g. what type/set should this function return?).

Thanks a lot for pointers to documentation/former postings or any help
Cheers
Chantal






^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: creating functional index over multiple columns
  2002-06-28 11:13 creating functional index over multiple columns Chantal Ackermann <chantal.ackermann@biomax.de>
@ 2002-06-29 04:19 ` Christopher Kings-Lynne <chriskl@familyhealth.com.au>
  0 siblings, 0 replies; 3+ messages in thread

From: Christopher Kings-Lynne @ 2002-06-29 04:19 UTC (permalink / raw)
  To: Chantal Ackermann <chantal.ackermann@biomax.de>; pgsql-sql

CREATE INDEX my_idx ON my_table(lower(name), type_id, syn_id); ???

Chris

----- Original Message ----- 
From: "Chantal Ackermann" <chantal.ackermann@biomax.de>
To: <pgsql-sql@postgresql.org>
Sent: Friday, June 28, 2002 7:13 PM
Subject: [SQL] creating functional index over multiple columns


> hello all,
> 
> I am new to this list, and I hope my request is well placed, here. I 
> tried searching the archives but I wasn't lucky.
> 
> I want to create an index over two columns and one function:
> 
> the WHERE clause is:
> WHERE lower(name)=? AND type_id=? AND syn_id=?
> 
> I know from the docs that I have to create on function that wraps these 
> three values for creating the appropriate index. I have practically no 
> idea how to do this (e.g. what type/set should this function return?).
> 
> Thanks a lot for pointers to documentation/former postings or any help
> Cheers
> Chantal
> 
> 
> 
> 
> ---------------------------(end of broadcast)---------------------------
> TIP 4: Don't 'kill -9' the postmaster
> 
> 






^ permalink  raw  reply  [nested|flat] 3+ messages in thread

* Re: creating functional index over multiple columns
@ 2002-06-28 11:22 Chantal Ackermann <chantal.ackermann@web.de>
  0 siblings, 0 replies; 3+ messages in thread

From: Chantal Ackermann @ 2002-06-28 11:22 UTC (permalink / raw)
  To: pgsql-sql

hello once more,

sorry, I just found Josh Berkus posting (Re: unique index on function 
and column). I thought (while reading the documentation) it would be 
better to have multicolumn indeces with "multicolumn" constraints. 
Obviously it makes no difference.

Chantal






^ permalink  raw  reply  [nested|flat] 3+ messages in thread


end of thread, other threads:[~2002-06-29 04:19 UTC | newest]

Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2002-06-28 11:13 creating functional index over multiple columns Chantal Ackermann <chantal.ackermann@biomax.de>
2002-06-29 04:19 ` Christopher Kings-Lynne <chriskl@familyhealth.com.au>
2002-06-28 11:22 Re: creating functional index over multiple columns Chantal Ackermann <chantal.ackermann@web.de>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox