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

support for notation with brackets inside MULTIPOINT

Details

    • Bug
    • Status: Open (View Workflow)
    • Major
    • Resolution: Unresolved
    • 10.5, 10.6, 10.11, 11.4, 11.8
    • 10.11
    • GIS
    • None

    Description

      MariaDB [test]> SELECT  st_astext(st_geomfromtext('multipoint((0 0))'));
      +-------------------------------------------------+
      | st_astext(st_geomfromtext('multipoint((0 0))')) |
      +-------------------------------------------------+
      | NULL                                            |
      +-------------------------------------------------+
      1 row in set (0,000 sec)
       
      MariaDB [test]> SELECT  st_astext(st_geomfromtext('multipoint((0 0),(1 1))'));
      +-------------------------------------------------------+
      | st_astext(st_geomfromtext('multipoint((0 0),(1 1))')) |
      +-------------------------------------------------------+
      | NULL                                                  |
      +-------------------------------------------------------+
      1 row in set (0,001 sec)
       
      MariaDB [test]> SELECT  st_astext(st_geomfromtext('multipoint(0 0,1 1)'));
      +---------------------------------------------------+
      | st_astext(st_geomfromtext('multipoint(0 0,1 1)')) |
      +---------------------------------------------------+
      | MULTIPOINT(0 0,1 1)                               |
      +---------------------------------------------------+
      1 row in set (0,001 sec)
      

      Mysql supports both ways - with brackets or without, but not the mix of them:

      mysql>  SELECT  st_astext(st_geomfromtext('multipoint(0 0,1 1)'));
      +---------------------------------------------------+
      | st_astext(st_geomfromtext('multipoint(0 0,1 1)')) |
      +---------------------------------------------------+
      | MULTIPOINT((0 0),(1 1))                           |
      +---------------------------------------------------+
      1 row in set (0,00 sec)
       
      mysql> SELECT ST_EQUALS( st_geomfromtext('point (0 0)') , st_geomfromtext('multipoint((0 0))'));
      +-----------------------------------------------------------------------------------+
      | ST_EQUALS( st_geomfromtext('point (0 0)') , st_geomfromtext('multipoint((0 0))')) |
      +-----------------------------------------------------------------------------------+
      |                                                                                 1 |
      +-----------------------------------------------------------------------------------+
      1 row in set (0,00 sec)
       
      mysql>  SELECT  st_astext(st_geomfromtext('multipoint((0 0),1 1)'));
      ERROR 3037 (22023): Invalid GIS data provided to function st_geomfromtext.
      mysql>  SELECT  st_astext(st_geomfromtext('multipoint((0 0),(1 1))'));
      +-------------------------------------------------------+
      | st_astext(st_geomfromtext('multipoint((0 0),(1 1))')) |
      +-------------------------------------------------------+
      | MULTIPOINT((0 0),(1 1))                               |
      +-------------------------------------------------------+
      1 row in set (0,00 sec)
      

      Attachments

        Activity

          There are no comments yet on this issue.

          People

            Gosselin Dave Gosselin
            alice Alice Sherepa
            Votes:
            0 Vote for this issue
            Watchers:
            3 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.