pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Edmund Bacon <ebacon@onesystem.com>
To: pgsql-sql <pgsql-sql@postgresql.org>
Subject: Re: Functional index and string concatenation
Date: Mon, 08 Mar 2004 08:28:07 -0700
Message-ID: <1078759686.10233.1.camel@elb_lx.onesystem.ca> (raw)
In-Reply-To: <404C8F08.2070403@yahoo.com.br>
References: <404C8F08.2070403@yahoo.com.br>

On Mon, 2004-03-08 at 08:19, Daniel Henrique Alves Lima wrote:
>     Is there a way to create a "functional index" over a string 
> concatenation of two columns ?
> 
>     Thanks.
> 
Like this?

test=# create table strtable (x int, str1 text, str2 text);
CREATE TABLE
test=# create index str_idx on strtable( textcat(str1, str2) );
CREATE INDEX
test=# 

-- 
Edmund Bacon <ebacon@onesystem.com>




view thread (5+ messages)  latest in thread

Message-ID: <1078759686.10233.1.camel@elb_lx.onesystem.ca>
Permalink:  ../1078759686.10233.1.camel@elb_lx.onesystem.ca/
Also on:    postgresql.org/message-id/1078759686.10233.1.camel@elb_lx.onesystem.ca

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: ebacon@onesystem.com
  Subject: Re: Functional index and string concatenation
  In-Reply-To: <1078759686.10233.1.camel@elb_lx.onesystem.ca>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

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