Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-13467

Feature request: Support for ST_Distance_Sphere()

Details

    Description

      Spatial Convenience Function:

      This function does not exist in any version of MariaDB but does on MySQL 5.7+ and is critical for spatial conversions. ST_Distance_Sphere makes use for calculating the distance of coordinates from points.

      For more information reference MySQL's documentation directly at:
      https://dev.mysql.com/doc/refman/5.7/en/spatial-convenience-functions.html

      Source Code Reference (thanks to Daniel Black for the commit number):
      https://github.com/mysql/mysql-server/commit/60e7f702ac3929c0e38afa7e6dd75fcd5a54c6a9

      Attachments

        Issue Links

          Activity

            Yi Yang Yi Yang added a comment - - edited

            I believe this might be causing a regression of MDEV-12462

            I have a CI running some ST_WITHIN() based address lookup, something like

            SELECT * FROM ST_WITHIN(@point, @polygon);
            

            was working fine in 10.4.18, but is not working in 10.4.19, returning empty result (the point is within the polygon).

            In 10.4.19 you have to use something like

            SELECT * FROM ST_WITHIN(@point, @polygon) = 1;
            

            or drop the index, to get the correct result.

            Can someone reopen the old issue or create a new issue and fix it?

            Yi Yang Yi Yang added a comment - - edited I believe this might be causing a regression of MDEV-12462 I have a CI running some ST_WITHIN() based address lookup, something like SELECT * FROM ST_WITHIN(@point, @polygon); was working fine in 10.4.18, but is not working in 10.4.19, returning empty result (the point is within the polygon). In 10.4.19 you have to use something like SELECT * FROM ST_WITHIN(@point, @polygon) = 1; or drop the index, to get the correct result. Can someone reopen the old issue or create a new issue and fix it?
            robin850 Robin Dupret added a comment -

            Thank you very much for working on this Anel ; really glad to see that feature in MariaDB, great addition. (And thanks for the credit in the commit.)

            robin850 Robin Dupret added a comment - Thank you very much for working on this Anel ; really glad to see that feature in MariaDB, great addition. (And thanks for the credit in the commit.)

            Pushed with 6769d1a0782f140dcd12c to 10.2 after passing protected branch.
            Will be merged soon to 10.3+.

            anel Anel Husakovic added a comment - Pushed with 6769d1a0782f140dcd12c to 10.2 after passing protected branch . Will be merged soon to 10.3+ .

            mikemcc Mike McCutcheon added a comment -
            bhelm Bernd Helm added a comment -

            Glad to hear! Thank you for your Work to make this happen!

            bhelm Bernd Helm added a comment - Glad to hear! Thank you for your Work to make this happen!

            People

              anel Anel Husakovic
              tfont Travis van der Font
              Votes:
              29 Vote for this issue
              Watchers:
              33 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Git Integration

                  Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.