Uploaded image for project: 'MariaDB Connector/C'
  1. MariaDB Connector/C
  2. CONC-125

Import and export popular data formats from and to dynamic columns

    XMLWordPrintable

Details

    • Task
    • Status: Open (View Workflow)
    • Major
    • Resolution: Unresolved
    • 2.1
    • None
    • None

    Description

      Provide import and export functions for popular data formats like JSON, XML (limited), PHP, ...
      for Connector/C and MariaDB Server (which use same code base for dynamic columns)

      Tasks:

      Dynamic column library (includes MariaDB Server and Connector/C).
      1) Add support for arrays with ordinal indexes (currently dynamic columns are limited to use string indexes only)
      2) Provide a library for importing/exporting data to and from Dynamic columns.
      The following data formats should be supported:

      • JSON
      • XML (limited to unique keys only)
      • PHP,
      • ...

      MariaDB Server:
      3) Provide user defined function (UDF) based on library (task 2) for importing and exporting data

      MariaDB Connector/C:
      3) Provide a plugin interface based on library (task 2) for importing and exporting data

      Examples of usage:

      1) MariaDB Server

      SET @a:='{"menu": {
        "id": "file",
        "value": "File",
        "popup": {
          "menuitem": [
            {"value": "New", "onclick": "CreateNewDoc()"},
            {"value": "Open", "onclick": "OpenDoc()"},
            {"value": "Close", "onclick": "CloseDoc()"}
          ]
        }
      }}';
      INSERT INTO my_table (dyncol) VALUES (COLUMN_IMPORT("JSON", @a))

      2) Connector/C

       char *json_str='{'menu': {
        'id': 'file',
        'value': 'File',
        'popup': {
          'menuitem': [
            {'value': 'New', 'onclick': 'CreateNewDoc()'},
            {'value': 'Open', 'onclick': 'OpenDoc()'},
            {'value': 'Close', 'onclick': 'CloseDoc()'}
          ]
        }
      }}";
      rc= mariadb_dyncol_import(dyncol, "json", json_str);

      Programming language: C

      Attachments

        Activity

          People

            georg Georg Richter
            georg Georg Richter
            Votes:
            1 Vote for this issue
            Watchers:
            6 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.