cannot index functions with multiple arguments

From: pgsql-bugs(at)postgresql(dot)org
To: pgsql-bugs(at)postgresql(dot)org
Subject: cannot index functions with multiple arguments
Date: 2001-01-31 15:51:53
Message-ID: 200101311551.f0VFpr438225@hub.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Scott Marlowe (smarlowe(at)ihs(dot)com) reports a bug with a severity of 2
The lower the number the more severe it is.

Short Description
cannot index functions with multiple arguments

Long Description
Postgresql version: 7.1beta2
OS: RedHat Linux 7.0

Postgresql allows indexing of functions applied to columns, like so:

create index yada on table (lower(column));

but this fails on functions like substr that have multiple arguments.

create index yada on table (substr(column,1,4));

fails like so:

ERROR: parser: parse error at or near "1"

Sample Code
Exact code as I typed it in, with response:

smarlowe=# create index exten_extension_idx on exten (substr(extension,1,4));
ERROR: parser: parse error at or near "1"

I hope this isn't a known bug and I'm reporting it again.

No file was uploaded with this report

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Stephan Szabo 2001-01-31 16:59:59 Re: cannot index functions with multiple arguments
Previous Message Peter Mount 2001-01-30 23:31:53 Re: [JDBC] no way in LargeObject API to detect short read?