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

VEC_FromText() and VEC_ToText() functions

Details

    Description

      Like ST_GeomFromText(), VEC_FromText() take a string with N floating point numbers (comma separated or not, in square brackets or not) and will return a binary string of N floats.

      will return VECTOR(N) value, when we'll have such a type.

      Like ST_AsText(), VEC_AsText() will take a binary string of N floats (or a VECTOR(N) value) and will return a text representation of it

      Attachments

        Issue Links

          Activity

            rdyas Robert Dyas added a comment -

            It seems like it would be cleaner if instead of calling text2binary and binary2text functions all the time the default input / output format is a string that conforms to a JSON array. The internal representation can of course be binary. So in clients, like Connector/J, you can just set/get a string for the values.

            rdyas Robert Dyas added a comment - It seems like it would be cleaner if instead of calling text2binary and binary2text functions all the time the default input / output format is a string that conforms to a JSON array. The internal representation can of course be binary. So in clients, like Connector/J, you can just set/get a string for the values.

            Yes, the text format is a string that conforms to a JSON array.

            But when the application has an array of floats, it's more efficient to sent it to the server in binary, instead of forcing the application to convert floats to json, send a — much larger — string and let the server convert the string back to an array of floats.

            So I'd like to allow direct binary array of floats too.

            serg Sergei Golubchik added a comment - Yes, the text format is a string that conforms to a JSON array. But when the application has an array of floats, it's more efficient to sent it to the server in binary, instead of forcing the application to convert floats to json, send a — much larger — string and let the server convert the string back to an array of floats. So I'd like to allow direct binary array of floats too.

            People

              cvicentiu Vicențiu Ciorbaru
              serg Sergei Golubchik
              Votes:
              1 Vote for this issue
              Watchers:
              15 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.