Problem with Layyer from PostgreSQL

Gloem f.glandorf at GMX.DE
Tue Oct 10 17:19:09 EDT 2006


Sorry, hab bei der sql-Datei was vergessen. Die ganze Fehlermeldung sieht nun
anders aus:

msDrawMap(): Image handling error. Failed to draw layer named 'PLZ'.
prepare_database(): Query error. Error executing POSTGIS DECLARE (the actual
query) statement: 'DECLARE mycursor BINARY CURSOR FOR SELECT
asbinary(force_collection(force_2d(the_geom)),'NDR'),gid::text from
post_code_areas WHERE the_geom && setSRID('BOX3D(5.5 46.15,15.2
55.85)'::BOX3D, find_srid('','post_code_areas','the_geom') )'

Postgresql reports the error as 'ERROR: find_srid() - couldnt find the
corresponding SRID - is the geometry registered in the GEOMETRY_COLUMNS
table? Is there an uppercase/lowercase missmatch? '

More Help:

Error with POSTGIS data variable. You specified '<check your .map file>'.
Standard ways of specifiying are :
(1) 'geometry_column from geometry_table'
(2) 'geometry_column from (<sub query>) as foo using unique <column name>
using SRID=<srid#>'

Make sure you put in the 'using unique <column name>' and 'using SRID=#'
clauses in. 


Die sql-Datei sieht nun folgendermaßen aus:
http://www.nabble.com/file/369/test.sql test.sql 


Gloem wrote:
> 
> Hello, 
> 
> I'm new to Mapserver. Maybe somecan here can help me:
> 
> I tried to set up a UMN Mapserver with some data I found on the net. But
> when I run the mapserver this message appeares:
> 
> msDrawMap(): Image handling error. Failed to draw layer named 'PLZ'.
> prepare_database(): Query error. Error executing POSTGIS DECLARE (the
> actual query) statement: 'DECLARE mycursor BINARY CURSOR FOR SELECT
> asbinary(force_collection(force_2d(the_geom)),'NDR'),OID::text from
> post_code_areas WHERE the_geom && setSRID('BOX3D(5.5 46.15,15.2
> 55.85)'::BOX3D, find_srid('','post_code_areas','the_geom') )'
> 
> Postgresql reports the error as 'ERROR: column "oid" does not exist '
> 
> More Help:
> 
> Error with POSTGIS data variable. You specified '<check your .map file>'.
> Standard ways of specifiying are :
> (1) 'geometry_column from geometry_table'
> (2) 'geometry_column from (<sub query>) as foo using unique <column name>
> using SRID=<srid#>'
> 
> Make sure you put in the 'using unique <column name>' and 'using SRID=#'
> clauses in.
> 
> 
> The data I wanted to used have this structure:
>  http://www.nabble.com/file/367/test.sql test.sql 
> 
> And my map file looks like this:
>  http://www.nabble.com/file/368/mapdatei_plz.map mapdatei_plz.map 
> 
> 
> I tried to use the same srid in the map-file as in the database but
> somehow this seems not to work correct.
> 
> Please help
> Frank
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Problem-with-Layyer-from-PostgreSQL-tf2417891.html#a6745718
Sent from the Mapserver - User mailing list archive at Nabble.com.



More information about the mapserver-users mailing list