hi all,
    i am a new bie to fgs and i want to test one of my mapfile with
connecting to my database.
    here is my mapfile


NAME "test"
SIZE 800 600
IMAGECOLOR 249 245 186
IMAGETYPE png
EXTENT -1.00 -1.00 1.00 1.00
LAYER
    CONNECTIONTYPE postgis
    NAME "test"
    CONNECTION "user=postgres password=hellopostgres dbname=postgres
host=localhost"
    DATA "geom FROM test"
    STATUS ON
    TYPE POINT
   END
END



whenever i test the file as *shp2img** *i get the following error


msDrawMap(): Image handling error. Failed to draw layer named 'test'. <br>
prepare_database(): Query error. Error executing POSTGIS DECLARE (the actual
query) statement: 'DECLARE mycursor BINARY CURSOR FOR SELECT
asbinary(force_collection(force_2d(geom)),'NDR'),OID::text from test WHERE
geom && setSRID('BOX3D(-1.3338898163606 -1,1.3338898163606 1)'::BOX3D,
find_srid('','test','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.

For more help, please see http://postgis.refractions.net/documentation/

Mappostgis.c - version of Jan 23/2004.
 <br>




   any solutions will be appreciated


   regards
   SyedMohseen
_______________________________________________
mapserver-users mailing list
mapserver-users@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/mapserver-users

Reply via email to