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

Wrong result from ST_UNION(..MULTIPOLYGON)

Details

    • Bug
    • Status: Confirmed (View Workflow)
    • Major
    • Resolution: Unresolved
    • 10.5, 10.6, 10.11, 11.4, 11.7(EOL)
    • 10.5, 10.6, 10.11, 11.4
    • GIS
    • None

    Description

      MariaDB [test]> select version();
      +-----------------------+
      | version()             |
      +-----------------------+
      | 10.5.28-MariaDB-debug |
      +-----------------------+
      1 row in set (0,001 sec)
       
      MariaDB [test]>  SELECT ST_astext(ST_UNION( ST_GEOMFROMTEXT('  MULTIPOLYGON( ( (3 5, 2 5, 2 4, 3 4, 3 5) ), ( ( 7 7, 2 7, 4 9, 7 1, 7 7 ) ), ( ( 2 2, 2 8, 8 8, 8 2, 2 2 ), ( 4 4, 4 6, 6 6, 6 4, 4 4 ) ) ) '),  ST_GEOMFROMTEXT('POLYGON((2 4,3 4,3 5,2 5,2 4))')  )) с ;
      +----------------------------------------------------------------------------------------------+
      | с                                                                                            |
      +----------------------------------------------------------------------------------------------+
      | POLYGON((7 1,6.625 2,2 2,2 8,3 8,4 9,4.375 8,8 8,8 2,7 2,7 1),(4 4,4 6,5.125 6,5.875 4,4 4)) |
      +----------------------------------------------------------------------------------------------+
      1 row in set (0,002 sec)
      

      mysql>  SELECT ST_astext(ST_UNION( ST_GEOMFROMTEXT('  MULTIPOLYGON( ( (3 5, 2 5, 2 4, 3 4, 3 5) ), ( ( 7 7, 2 7, 4 9, 7 1, 7 7 ) ), ( ( 2 2, 2 8, 8 8, 8 2, 2 2 ), ( 4 4, 4 6, 6 6, 6 4, 4 4 ) ) ) '),  ST_GEOMFROMTEXT('POLYGON((2 4,3 4,3 5,2 5,2 4))')  )) с ;
      +-------------------------------------------------------------------------------------+
      | с                                                                                   |
      +-------------------------------------------------------------------------------------+
      | MULTIPOLYGON(((7 7,2 7,4 9,7 1,7 7)),((2 8,2 2,8 2,8 8,2 8),(4 4,4 6,6 6,6 4,4 4))) |
      +-------------------------------------------------------------------------------------+
      1 row in set (0,00 sec)
       
      mysql> select version();
      +-----------+
      | version() |
      +-----------+
      | 9.1.0     |
      +-----------+
      1 row in set (0,00 sec)
      

      Attachments

        Activity

          There are no comments yet on this issue.

          People

            holyfoot Alexey Botchkov
            alice Alice Sherepa
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:

              Git Integration

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