[postgis-users] About Invalid OGC WKT Error
Kralidis,Tom [Burlington]
Tom.Kralidis at ec.gc.ca
Thu Feb 3 06:15:11 PST 2005
> -----Original Message-----
> From: postgis-users-bounces at postgis.refractions.net
> [mailto:postgis-users-bounces at postgis.refractions.net] On
> Behalf Of strk at refractions.net
> Sent: Thursday, 03 February, 2005 08:36
> To: PostGIS Users Discussion
> Subject: Re: [postgis-users] About Invalid OGC WKT Error
>
>
> On Wed, Feb 02, 2005 at 06:22:56PM -0500, Kralidis,Tom
> [Burlington] wrote:
> >
> > Here's what shows up in my error logs when MapServer attempts to
> > access when I have MapServer in debugging mode:
>
> (cuts)
>
> > query_string_0_6:DECLARE mycursor BINARY CURSOR FOR SELECT
> > asbinary(force_collection(force_2d(the_geom)),'NDR'),OID::text from
> > service_endpoints WHERE the_geom && setSRID('BOX3D(-141.089
> > 36.392987,-52.089 89.784987)'::BOX3D,
> > find_srid('','service_endpoints','the_geom') )
>
> (cuts)
>
> > msPOSTGISLayerClose -- query_result is NULL
>
>
> That query does not return any result. Check manually
> invoking it.
When I manually invoke, I get records:
devgeodb=# select astext(the_geom) from service_endpoints ;
astext
------------------------------------------------------------------------
------------------
POLYGON((-141.089 36.393,-141.089 89.785,-52.089 89.785,-52.089
36.393,-141.089 36.393))
(1 row)
devgeodb=# select asbinary(the_geom) from service_endpoints ;
asbinary
------------------------------------------------------------------------
------------------------------------------------------------------------
------------
------------------------------------------------------------------------
--------------------------------------------
\001\003\000\000\000\001\000\000\000\005\000\000\000\002+\207\026\331\24
2a\300\374\251\361\322M2B@\002+\207\026\331\242a\300\012\327\243p=rV@\01
0\254\034Zd
\013J\300\012\327\243p=rV@\010\254\034Zd\013J\300\374\251\361\322M2B@\00
2+\207\026\331\242a\300\374\251\361\322M2B@
(1 row)
...so I know there's data in the table.
>Also, check:
>
> # SELECT extent(asbinary(force_collection(force_2d(the_geom)),'NDR'));
Appending "from <tablename>" makes this query work:
devgeodb=# SELECT
extent(asbinary(force_collection(force_2d(the_geom)),'NDR')) from
service_endpoints ;
extent
------------------------------------------------------------------------
---
BOX(-141.089004516602 36.3929977416992,-52.088996887207
89.7850036621094)
(1 row)
> # SELECT setSRID('BOX3D(-141.089 36.392987,-52.089 89.784987)'::BOX3D,
> find_srid('','service_endpoints','the_geom') )
>
devgeodb=# SELECT setSRID('BOX3D(-141.089 36.392987,-52.089
89.784987)'::BOX3D,find_srid('','service_endpoints','the_geom') );
setsrid
------------------------------------------------------------------------
------------------------------------------------------------------------
------------
----------------------------------------
0103000020E61000000100000005000000022B8716D9A261C06760E4654D324240022B87
16D9A261C040321D3A3D72564008AC1C5A640B4AC040321D3A3D72564008AC1C5A640B4A
C06760E4654
D324240022B8716D9A261C06760E4654D324240
(1 row)
> --strk;
> _______________________________________________
> postgis-users mailing list postgis-users at postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users
>
More information about the postgis-users
mailing list