Re: Syntax problem with INDEX on expression

From: Mike Blackwell <mike(dot)blackwell(at)rrd(dot)com>
To: Kevin Grittner <kgrittn(at)ymail(dot)com>
Cc: pgsql-general <pgsql-general(at)postgresql(dot)org>
Subject: Re: Syntax problem with INDEX on expression
Date: 2013-04-05 21:20:06
Message-ID: CANPAkgtxWAoEaFtDWDR=SdVJ7FkBBdUFHGgmjWHkodqYTT-+-w@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

So, one set to mark the parameter and one for the expression? It's
starting to look like Lisp. ^_^

Thanks!

__________________________________________________________________________________
*Mike Blackwell | Technical Analyst, Distribution Services/Rollout
Management | RR Donnelley*
1750 Wallace Ave | St Charles, IL 60174-3401
Office: 630.313.7818
Mike(dot)Blackwell(at)rrd(dot)com
http://www.rrdonnelley.com

<http://www.rrdonnelley.com/>
* <Mike(dot)Blackwell(at)rrd(dot)com>*

On Fri, Apr 5, 2013 at 4:18 PM, Kevin Grittner <kgrittn(at)ymail(dot)com> wrote:

> Mike Blackwell <mike(dot)blackwell(at)rrd(dot)com> wrote:
>
> > sp_dev=# create index test_idx on test
> ((xpath('//rms:xsid/text()',udh,array[array['rms','http://www.example.com
> ']]))[1]::text);
> > ERROR: syntax error at or near "["
> > LINE 1: ...udh,array[array['rms','http://www.example.com
> ']]))[1]::text)...
> > ^
> > It looks like it doesn't like the array subscript. What might I be
> missing?
>
> You're missing a set of parentheses around the entire expression.
>
> create index test_idx on test
> (((xpath('//rms:xsid/text()',udh,array[array['rms','http://www.example.com
> ']]))[1]::text));
>
> --
> Kevin Grittner
> EnterpriseDB: http://www.enterprisedb.com
> The Enterprise PostgreSQL Company
>

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Gavan Schneider 2013-04-05 21:54:11 Re: BEFORE UPDATE trigger doesn't change column value
Previous Message Kevin Grittner 2013-04-05 21:18:30 Re: Syntax problem with INDEX on expression