[Gdal-dev] PostGis layers
Frank Warmerdam
warmerdam at pobox.com
Fri Sep 23 10:08:25 EDT 2005
On 9/23/05, Oleg Semykin <oss-dev at rambler.ru> wrote:
> Hi, Frank
>
> But what about older PostreSQL 7.X version support:
>
> "Unable to identify an operator '=' for types 'name' and 'varchar'
> You will have to retype this query using an explicit cast"
>
> See: http://lists.maptools.org/pipermail/gdal-dev/2005-August/006098.html
Oleg,
Doh! Is there a way of explicitly casting that will work fine on old
and newer without having to use the ~ operator? How about:
select c.relname from pg_class c, geometry_columns g where (c.relkind
in ('r','v') AND c.relname !~ '^pg' AND c.relname::text =
g.f_table_name::text);
That seems to work on my 7.1 database and my 8.x database. I'll
commit that.
Best regards,
--
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush | Geospatial Programmer for Rent
More information about the Gdal-dev
mailing list