[Geomoose-users] Asking technical problem regarding displaying shape file

Brent Fraser bfraser at geoanalytic.com
Thu May 8 06:33:03 PDT 2014


Amila,

   Please make sure you reply to the Geomoose list as well so others can 
benefit.

Use Mapserver's shp2imge command line program to track down problems 
with your map file.; it is included with MS4W.  It will show error 
messages for problems it finds (also look in mapserver's error log).   
You can use GDAL's ogrinfo command to check the PostGIS database connection.

   The most common reason for data not displaying is an error in 
specifying the coordinate systems.  Below is a guess, since I don't know 
the details of your PostGIS table (have a look at 
http://mapserver.org/input/vector/postgis.html):

     # Use X Y X Y:
     EXTENT 456029 801937 467996 808358


     LAYER
         NAME 'kysitesutmrd1'
         STATUS ON
         TYPE POINT

         # ---- Same As EPSG:4326 in DATA object below ----
         PROJECTION
           "+proj=longlat +ellps=WGS84 +datum=WGS84 +no_defs"
         END

         CONNECTIONTYPE postgis
         CONNECTION 'host=localhost dbname=postgis_21_sample 
user=postgres password=postgres port=5432'
         DATA 'wkb_geometry from kysitesutmrd using unique gid using 
srid=4326'

         CLASS
             #NAME 'KYsites'
             # --- Should use STYLE object instead: ---
             COLOR 254 0 0
             SYMBOL "star"
             SIZE 8
          END# CLASS

     END # LAYER




Best Regards,
Brent Fraser

On 5/7/2014 11:01 PM, Amila Karunathilake wrote:
> Dear sir,
>
> Thank you very much for your quick reply for my problem.
>
> Sir, I have incorporate changes you have mention,
>
> 1. EXTENT 8887274.859924 787036.529767 9096903.423788 852344.927174
>
> 2. PROCESSING "CLOSE_CONNECTION=DEFER"
>
> Now, pink color display not appearing any more but points(.shp) were 
> not displaying...?
>
> Sir, Previously i directly stored data (.shp, .tiff..) in countydata
> folder (C:\ms4w\apps\thilankamaps\maps\demo\countydata).
> Then all the shp's were nicely displayed.
>
> But lastweek this problem occurs while i try to connect my geomoose 
> application to
> the postgis databases.
>
> Herewith i attached my old shp + map files (KYsitesUTM and msitesTW) 
> which properly work with geomoose (mapserver)
>
> But problem is why new map file with database connectivity codes, not 
> display properly....?
>
> Sir, your kind help is highly appreciated, because in Srilanka we do 
> not have any web GIS
> specialist in the field.
>
> Thank you again for you consideration.
>
> Amila.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/geomoose-users/attachments/20140508/7e46f73b/attachment.html>


More information about the Geomoose-users mailing list