[Mapserver-users] PostGIS questions - help with mapserver

Swaminathan, Gayathri gayathri at ou.edu
Mon Jul 7 18:40:02 EDT 2003


Hi Zamil,
In the DATA you are saying "GEOM FROM OILWELLS"
Is it really GEOM (column name of geometry in oilwells table, normally it is
somethin like, "the_geom"

And the msDrawMap() error is because it was not able to get DATA..

Please do also check that the table name OILWELLS is in CAPS??..I think
Postgres is case sensitive.
HTH,
Gayathri


-----Original Message-----
From: Zamil Murji [mailto:Zamil.Murji at divestco.com] 
Sent: Monday, July 07, 2003 4:30 PM
To: mapserver-users at lists.gis.umn.edu
Subject: [Mapserver-users] PostGIS questions - help with mapserver


Hi List,

Here is my situation:
1) From the server, I can ping the postgis server and I can telnet into it
on the correct port (5432).
2) From the postgis server, I can login to the db using psql command. The
command I used looks similar to the CONNECTION string my .map file.
3) I can select the geometry from the table.
4) Basically, I can do everything mentioned in the Wiki.

After all this, I cannot display the layer using mapserver. I keep getting
the following error: 
msDrawMap(): Image handling error. Failed to draw layer named 'oilwells'. 

Here is my .map layer definition:
#PostGIS Data Layer
LAYER
   NAME "oilwells"
   TYPE point
   STATUS default
   CONNECTIONTYPE postgis
   CONNECTION "user=idc dbname=idc host=sdb2 port=5432" 
   DATA "GEOM FROM OILWELLS" 
   CLASS
     COLOR 0 0 0
     SYMBOL 'circle'
     SIZE 20
#     TEMPLATE "c:\\mapfiles\test.html"
   END
END

I have indexed geom using gist syntax. How do I verify this index exists? 

Here is my table:
idc=# select * from oilwells;
 id |                 geom
----+--------------------------------------
  1 | SRID=4326;POINT(-110.04146 49.01449)
  2 | SRID=4326;POINT(-110.24459 49.01449)
  3 | SRID=4326;POINT(-110.43138 49.01449)
(3 rows)

What am I missing?
Thank you very much for your help.
Zamil

_______________________________________________
Mapserver-users mailing list
Mapserver-users at lists.gis.umn.edu
http://lists.gis.umn.edu/mailman/listinfo/mapserver-users



More information about the mapserver-users mailing list