| Bug #79407 | ST_within and ST_contains return inconsistent results | ||
|---|---|---|---|
| Submitted: | 25 Nov 2015 10:39 | Modified: | 25 Nov 2015 12:03 |
| Reporter: | Sebastian Hönel | Email Updates: | |
| Status: | Can't repeat | Impact on me: | |
| Category: | MySQL Server: GIS | Severity: | S2 (Serious) |
| Version: | 5.7.9 GA | OS: | Any |
| Assigned to: | CPU Architecture: | Any | |
| Tags: | gis, spatial, ST_Contains, st_within | ||
[25 Nov 2015 10:39]
Sebastian Hönel
[25 Nov 2015 11:54]
MySQL Verification Team
Thank you for the bug report. I was able to repeat with 5.7.9 released version but not anymore with source server:
mysql> set @p = st_GeomFromText('POINT(14.822664 56.858916)');
Query OK, 0 rows affected (0.00 sec)
mysql> select area_id, st_contains(boundary, @p) from test;
+---------+---------------------------+
| area_id | st_contains(boundary, @p) |
+---------+---------------------------+
| 209 | 1 |
| 299 | 1 |
| 2417 | 1 |
| 26621 | 0 |
+---------+---------------------------+
4 rows in set (0.01 sec)
mysql> show variables like "%version%";
+-------------------------+------------------------------+
| Variable_name | Value |
+-------------------------+------------------------------+
| innodb_version | 5.7.9 |
| protocol_version | 10 |
| slave_type_conversions | |
| version | 5.7.9 |
| version_comment | MySQL Community Server (GPL) |
| version_compile_machine | x86_64 |
| version_compile_os | Win64 |
+-------------------------+------------------------------+
7 rows in set (0.00 sec)
mysql 5.7 > set @p = st_GeomFromText('POINT(14.822664 56.858916)');
Query OK, 0 rows affected (0.00 sec)
mysql 5.7 > select area_id, st_contains(boundary, @p) from test;
+---------+---------------------------+
| area_id | st_contains(boundary, @p) |
+---------+---------------------------+
| 209 | 1 |
| 299 | 1 |
| 2417 | 1 |
| 26621 | 1 |
+---------+---------------------------+
4 rows in set (0.01 sec)
mysql 5.7 > show variables like "%version%";
+-------------------------+---------------------------------------+
| Variable_name | Value |
+-------------------------+---------------------------------------+
| innodb_version | 5.7.10 |
| protocol_version | 10 |
| slave_type_conversions | |
| version | 5.7.10 |
| version_comment | Source distribution PULL: 2015-NOV-07 |
| version_compile_machine | x86_64 |
| version_compile_os | Win64 |
+-------------------------+---------------------------------------+
7 rows in set (0.00 sec)
mysql 5.7 >
[25 Nov 2015 12:03]
Sebastian Hönel
Thanks for checking/verifying the described behavior. So I guess this is already fixed in the next version (5.7.10+) which will then (when?) be released, right? For clarification, you set this bug to "Can't repeat" because it cannot be repeated in a version newer than 5.7.9?
[25 Nov 2015 12:07]
MySQL Verification Team
Sorry but I don't know when will be released. Yes the can't repeat is with current source build server with a note it was repeatable with reported version. Thanks.
