HELP-Virtual Spatial Data

Frank Fica simbiotico at HOTMAIL.COM
Mon Dec 19 00:51:16 EST 2005


Hello,

I'm testing an OGR ODBC connection to my postgresql database to map Lat and Lon columns, but
when I test my file.map I only get a blank screen and no errors.
When I test with ogrinfo I get all the columns listed including the new POINT column with my
coordinates, works fine.

Here's my ovf file:

<OGRVRTDataSource>
    <OGRVRTLayer name="sorento">
        <SrcDataSource>ODBC:@PostgreSQL</SrcDataSource>
        <SrcLayer>record</SrcLayer>
        <GeometryType>wkbPoint</GeometryType>
        <LayerSRS>WGS84</LayerSRS>
        <GeometryField encoding="PointFromColumns" x="Lat" y="Lon"/>
    </OGRVRTLayer>
</OGRVRTDataSource>

Here's my file.map:

MAP
  IMAGETYPE PNG
  EXTENT -92.241493 13.738197 -88.223198 17.815220
  SIZE 640 480
  PROJECTION
   "proj=latlong"
   "ellps=WGS84"
   "datum=WGS84"
  END

  SYMBOL
   NAME 'circle'
   TYPE ELLIPSE
   FILLED TRUE
   POINTS
    1 1
   END
  END

 LAYER
    NAME "sorento"
    TYPE POINT
    CONNECTIONTYPE OGR
    CONNECTION "virtual.ovf" # the name and path to the virtual.ovf file, relative to shapepath may
work?
    DATA "sorento" # the name of the OGRVrtLayer
    STATUS DEFAULT
    CLASS
      SYMBOL "circle"
      SIZE 6
      COLOR 255 0 0
    END
 END
END



More information about the mapserver-users mailing list