3

I'm wanting to put polygons into a MySQL database and then with PHP be able to query if a latitude/longitiude point is inside the polygon.

Any pointers here. Never done anything like this yet.

1 Answers1

2

MySQL supports Spacial columns and functions using an extension which is quite often installed by default.

MySQL Reference for spacial features

How to use MySQL Spacial extension

Skrol29
  • 5,402
  • 1
  • 20
  • 25
  • 2
    These features were significantly upgraded in MySQL 5.6.1 - they [moved beyond MBR](http://dev.mysql.com/doc/refman/5.6/en/functions-for-testing-spatial-relations-between-geometric-objects.html#functions-that-test-spatial-relationships-between-geometries). The second link was written **before** that happened, the first link is to the latest documentation (**after** that happened) – MarkJ Dec 19 '11 at 17:02