Creating objects on the fly from the database

Doyon, Jean-Francois Jean-Francois.Doyon at CCRS.NRCan.gc.ca
Tue Sep 19 09:54:52 EDT 2000


You sure can.

Just use mapscript (For perl or PHP), to create a temporary shapefile that
will be used as a layer in the end product.

You would use for instance perl to interface with the database, and use the
appropriate mapscript functions
to put this data into a temporary shapefile.  You then define the layer as
needed, using the said shapefile as the data
source.  If you need to, you can use the PROJ.4 support to do on-the-fly
projection conversion if say your DB dataset
returns geographical coordinates, but your base layers are ins some other
projection (Which they most likely would be).

Hope this helps !
J.F.

> ----------
> From: 	Niels van Dijk[SMTP:Niels at nieuwland.nl]
> Sent: 	Tuesday, September 19, 2000 7:06 AM
> To: 	mapserver-users at lists.gis.umn.edu
> Subject: 	Creating objects on the fly from the database
> 
> Hi All,
> I'm a newbie with the Mapserver, so I'm sorry if i'm asking things
> allready 
> discussed, but I couldn't find anything about this in the Archives.
> - I want to add data from a database containing geographical coordinates 
> and some label dynamically to the map, to create so called event themes. 
> Can this be done?
> - I'd like to be able to use the coordinates of the map to dynamically 
> create point on the map and add these to a database.
> 
> thanks in advance
> Niels van Dijk 
> 



More information about the mapserver-users mailing list