ERROR: cannot subscript type text because it is not an array

From: lxnf98mm(at)comcast(dot)net
To: pgsql-sql(at)postgresql(dot)org
Subject: ERROR: cannot subscript type text because it is not an array
Date: 2011-08-31 13:26:57
Message-ID: alpine.LRH.2.00.1108310820490.21634@rray.drdc.mstc.ms.gov
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

I have table with field l type lseg

Column | Type | Modifiers
--------+---------+-----------
cnt | integer |
used | boolean |
l | lseg |
c | text |

select l from t where used = false group by l[0];
ERROR: cannot subscript type text because it is not an array

select l from gcode where used = false group by l[0][0],l[0][1];
ERROR: cannot subscript type text because it is not an array

Using PostgreSQL 8.3.11
How can I work around this

Richard

Browse pgsql-sql by date

  From Date Subject
Next Message Pavel Stehule 2011-08-31 16:16:02 Re: where col1 not ilike ('str1%', 'str2%'... 'strN%') support?
Previous Message Emi Lu 2011-08-31 12:54:32 Re: where col1 not ilike ('str1%', 'str2%'... 'strN%') support?