From: | Philip Hallstrom <philip(at)adhesivemedia(dot)com> |
---|---|
To: | Lamar Owen <lamar(dot)owen(at)wgcr(dot)org> |
Cc: | Mike Mascari <mascarm(at)mascari(dot)com>, pgsql-general(at)postgresql(dot)org |
Subject: | Re: Re: Lock up on 7.0.2 involving CREATE FUNCTION/INDEX.. |
Date: | 2000-08-10 03:40:14 |
Message-ID: | Pine.BSF.4.21.0008092039420.80432-100000@illiad.adhesivemedia.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Yes... it is odd... especially since the following works fine:
SELECT UPPER(field) FROM test;
-philip
On Wed, 9 Aug 2000, Lamar Owen wrote:
> Philip Hallstrom wrote:
> > CREATE INDEX test_idx ON test (UPPER(field));
>
> > devloki=> create index foo on rolo_entry (UPPER(fname));
> > ERROR: DefineIndex: function 'upper(varchar)' does not exist
> > devloki=> create index foo on rolo_entry (UPPER(varchar(fname)));
> > ERROR: parser: parse error at or near "varchar"
> > devloki=> create index foo on rolo_entry (UPPER(text(fname)));
> > ERROR: parser: parse error at or near "("
> > devloki=> create index foo on rolo_entry (UPPER(text fname));
> > ERROR: parser: parse error at or near "fname"
> > devloki=> create index foo on rolo_entry (UPPER(fname::text));
> > ERROR: parser: parse error at or near "::"
> > devloki=> create index foo on rolo_entry (UPPER(CAST(fname AS TEXT)));
> > ERROR: parser: parse error at or near "cast"
>
> > So, by creating a function such as UPPER(varchar) instead of the built-in
> > UPPER(text), I can do what I want.
>
> > What's odd, is that I can create the function UPPER(varchar) which then
> > calls UPPER(text) and use it all I want. However, if I then try to create
> > an index (like my first example above) it locks up the entire machine.
>
> That is wild. I'd say bring this up in the hackers list -- as upper
> should also work with varchar by default.
>
> --
> Lamar Owen
> WGCR Internet Radio
> 1 Peter 4:11
>
From | Date | Subject | |
---|---|---|---|
Next Message | Dale Walker | 2000-08-10 04:55:09 | insert into table from select.. |
Previous Message | Lamar Owen | 2000-08-10 03:26:00 | Re: Re: Lock up on 7.0.2 involving CREATE FUNCTION/INDEX.. |