[mapserver-users] MapServer problem

Kralidis,Tom [Ontario] Tom.Kralidis at ec.gc.ca
Mon Feb 23 13:48:35 EST 2009


> Hi Mapserver users,
> 
> 
> I am trying to display few points on the browser using 
> Mapserver. I have created MySQL database and created 
> connection with mapserver by the help of .ovf xml file.
> 
> 
> -------------------------------------------------
> 
> 
> <OGRVRTDataSource>
> 
>     <OGRVRTLayer name="nsdb"> 
> 
>              
> <SrcDataSource>MYSQL:dispro,user=uuuuuu,password=pppp,host=192
> .170.1.100,port=3306,tables=STATION</SrcDataSource> 
> 
>         <SrcSQL>SELECT absnum, stlat, stlon, stflag FROM 
> STATION</SrcSQL> 
> 
>         <GeometryType>wkbPoint</GeometryType>
> 
>         <GeometryField encoding="PointFromColumns" x="stlon" 
> y="stlat"/> 
> 
>     </OGRVRTLayer>
> 
> </OGRVRTDataSource>
> 
> --------------------------------------------------
> 
> 
> 
> 
> When I run the command :
> ogrinfo  /mnt/fritjof/wms/nsdb/con.ovf 
> 
> ogrinfo returns :
> 
> 
> 
> ERROR 4: Update access not supported for VRT datasources.
> 
> Had to open data source read-only.
> 
> INFO: Open of `/mnt/fritjof/wms/nsdb/con.ovf'
> 
>       using driver `VRT' successful.
> 
> 1: nsdb (Point)
> ..............................................................
> ..............................................................
> .........
> 
> Version details of mapserver and GDAL as follows: 
> 
> $ ./mapserv -v
> MapServer version 4.10.3 OUTPUT=GIF OUTPUT=PNG OUTPUT=JPEG 
> OUTPUT=WBMP OUTPUT=PDF OUTPUT=SVG SUPPORTS=PROJ 
> SUPPORTS=FREETYPE SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT 
> SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT 
> 
> 
> SUPPORTS=WCS_SERVER SUPPORTS=THREADS INPUT=EPPL7 INPUT=OGR 
> INPUT=GDAL INPUT=SHAPEFILE DEBUG=MSDEBUG
> 
> 
> $ gdal-config --version
> 1.5.3
> - Show quoted text -
> 
> I have a map file con.map as follows:
> -------------------------------------------------------------
> MAP
>   NAME "MYSQL-TEST"
>   EXTENT  -180 -90 180 90  
>   UNITS dd
>   CONFIG "CPL_DEBUG" "ON"
> 
>   PROJECTION
>   "init=epsg:4326"
>   END
> 
>   SHAPEPATH "/mnt/fritjof/wms/nsdb"
> 
>   LAYER
>     DEBUG ON
>     METADATA
>       "wms_title" "nsdb"
>       "wms_srs" "EPSG:4326"
>       "wms_extent" "-57.768 64.1842 -51.6283 64.3645"
>     END
>     NAME "stations" 
>     STATUS DEFAULT 
>     TYPE POINT
>     CONNECTIONTYPE OGR
>     CONNECTION "con.ovf"
>     DATA "nsdb"
>     PROJECTION
>       "init=epsg:4326"
>     END
>     EXTENT -57.768 64.1842 -51.6283 64.3645
>     CLASS
>       NAME "MyClass"
>       STYLE
>         SYMBOL 1
>         SIZE 15
>         COLOR 255 0 0
>           END
>     END
>  END
> 
> END

You're pointing to a SYMBOL that doesn't exist.  Either comment that
out, or make sure your mapfile references a SYMBOLSET file.

..Tom


> ........................................
> 
> And I have another html form from where I am trying to 
> display in browser the Latitude and longitude points which 
> are stored in database.  
> 
> 
> ========================================================
> 
> 
> MAPFILE        
> REQUEST       
> SERVICE        
> VERSION       
> LAYERS              
> STYLES          
> SRS                  
> BBOX              
> WIDTH            
> HEIGHT          
> FORMAT        
> 
> 
> 
> 
> 
>  
> 
> 
> 
> =========================================
> 
> But Mapserver is displaying nothing and does not giving any 
> error. Just it's showing a blank map. Could you tell me Why??
> What's the problem may be happen??
> Thanking you.
> Regards,
> Phalguni 
> 
> 


More information about the mapserver-users mailing list