Wide Open Spaces: Using MySQL as a Web Mapping Service Backend

LAMP, PHP and MySQL, Web 2.0, Ajax, and Emerging Technologies
Location: Ballroom E Level: Intermediate
Average rating: ***..
(3.00, 1 rating)

Even without being the problems of a nonexistent software budget and a 6 month time constraint, the task of serving out geo-spatial data in a Web Mapping Service (WMS) format is daunting. Many organizations in this position have opted to buy commercial licenses from a well established geo-spatial company and be done with it. Often times this requires buying a proprietary geo-spatial software package, a proprietary database license and expert help with installation. However, this does not reduce the need for personnel to maintain the system, create new WMS layers, and update the database with new geo-spatial data.

We were given the above problem and constraints in dealing with an experiment that was designed to test the use of geo-spatial information sharing amongst different government organizations. Our presentation will go about how to do this with a completely open source solution.

The first step was to get an open source WMS server. For this task we chose the Minnesota MapServer software tool. MapServer is an Open Source development environment for building spatially-enabled internet applications. It includes the ability to set up WMS according to Open Geographical Consortium (OGC) standards. Basic background of Mapserver will be presented and there will be discussion of its ability as well as its limitations of integrating with MySQL through the Geospatial Data Abstraction Library (GDAL) OGR library.

The second step was to set up the MySQL database backend. MySQL spatial type columns were used to store the geo-spatial data, and spatial indicies were applied to these columns. A determination had to be made of how to get geo-spatial information into the service. This was done in two ways. The first was using scripting to take shapefiles and import those into MySQL tables. The second was to build a “point and click” interface in which a user was able to create simple point, multi-point, line, and polygon shapes and save those directly to the correct WMS layer. This front end was a mashup of Google Maps, PHP, and javascript.

Finally there was the interaction piece. Our system had to interact with commercial and open source WMS viewers used by the participants of the experiment. We soon learned the fact that not all standards are created equal, or rather that not everyone who builds a geo-spatial viewer adheres to the same standard. This provided a new set of problems to solve and also required us to create a Web Feature Service (WFS) to link in data about each of the geo-objects placed on the map.

In conclusion, this presentation will cover the above topics and get into an in depth discussion about how MySQL fit in to each of the problems we overcame, and how the spatial features of MySQL could be expanded in order to add more features to the products that we have designed.

Don Beesing

Alion Science and Technology

Don Beesing is a Senior Programmer for Alion Science and Technology. He has five years experience in the fields of database administration, database programming, and web development.

Don has also co-authored a paper titled “Simulation vs. Stimulation” that was presented at the Interservice/Industry Training, Simulation and Education Conference (IITSEC) in December of 2008.

Don graduated from Hiram College (Hiram, OH) with a Bachelor’s Degree in Computer Science.

Co-presented By:

O'Reilly Media MySQL/Sun Microsystems
  • Kickfire
  • Virident
  • Infobright, Inc
  • JasperSoft
  • Intel
  • Advanced Micro Devices
  • BIRT Exchange by Actuate
  • Calpont
  • Canonical
  • Continuent
  • Dolphin Interconnect Solutions
  • Facebook
  • HiT Software, Inc.
  • IBM
  • iDashboards
  • Oracle
  • Pentaho
  • R1Soft
  • Schooner Information Technology
  • SQLstream
  • Ticketmaster
  • Zmanda, Inc.
  • Linux Journal

Sponsorship Opportunities

For information on exhibition and sponsorship opportunities at the conference, contact Sharon Cordesse at scordesse@oreilly.com

Download the MySQL Sponsor/Exhibitor Prospectus

Media Partner Opportunities

Download the Media & Promotional Partner Brochure (PDF) for information on trade opportunities with O'Reilly conferences or contact mediapartners@ oreilly.com

Press and Media

For media-related inquiries, contact Maureen Jennings at maureen@oreilly.com

MySQL Conference Newsletter

To stay abreast of conference news and to receive email notification when registration opens, please sign up for the MySQL Conference newsletter.

Contact Us

View a complete list of MySQL contacts.