diff options
Diffstat (limited to 'django')
| -rw-r--r-- | django/contrib/gis/db/backends/mysql/operations.py | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/django/contrib/gis/db/backends/mysql/operations.py b/django/contrib/gis/db/backends/mysql/operations.py index cfd780022f..de64bc95db 100644 --- a/django/contrib/gis/db/backends/mysql/operations.py +++ b/django/contrib/gis/db/backends/mysql/operations.py @@ -34,8 +34,11 @@ class MySQLOperations(BaseSpatialOperations, DatabaseOperations): } function_names = { + 'Difference': 'ST_Difference', 'Distance': 'ST_Distance', + 'Intersection': 'ST_Intersection', 'Length': 'GLength', + 'SymDifference': 'ST_SymDifference', 'Union': 'ST_Union', } @@ -48,12 +51,12 @@ class MySQLOperations(BaseSpatialOperations, DatabaseOperations): def unsupported_functions(self): unsupported = { 'AsGeoJSON', 'AsGML', 'AsKML', 'AsSVG', 'BoundingCircle', - 'Difference', 'ForceRHR', 'GeoHash', 'Intersection', 'MemSize', + 'ForceRHR', 'GeoHash', 'MemSize', 'Perimeter', 'PointOnSurface', 'Reverse', 'Scale', 'SnapToGrid', - 'SymDifference', 'Transform', 'Translate', + 'Transform', 'Translate', } if self.connection.mysql_version < (5, 6, 1): - unsupported.update({'Distance', 'Union'}) + unsupported.update({'Difference', 'Distance', 'Intersection', 'SymDifference', 'Union'}) return unsupported def geo_db_type(self, f): |
