Uploaded image for project: 'Apache Drill'
  1. Apache Drill
  2. DRILL-6835 Schema Provision using File / Table Function
  3. DRILL-7073

CREATE SCHEMA command / TupleSchema / ColumnMetadata improvements

    XMLWordPrintableJSON

Details

    • Sub-task
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 1.16.0
    • None

    Description

      CREATE SCHEMA command improvements:
      1. add format
      2. add default
      3. add column properties

      TupleSchema / ColumnMetadata improvements:
      1. add properties map;
      2. add format;
      3. add default from string literal;
      4. add ser / de methods.

      Example:

      create schema 
      (col date not null format 'yyyy-MM-dd' default '2018-12-31' properties { 'prop1' = 'val1', 'prop2' = 'val2' })
      path '/path/to/schema'
      

      The following schema will be created:

      {
        "schema" : {
          "columns" : [
            {
              "name" : "col",
              "type" : "DATE",
              "mode" : "REQUIRED",
              "format" : "yyyy-MM-dd",
              "default" : "2018-12-31",
              "properties" : {
                "prop2" : "val2",
                "prop1" : "val1"
              }
            }
          ]
        },
        "version" : 1
      }
      

      Attachments

        Issue Links

          Activity

            People

              arina Arina Ielchiieva
              arina Arina Ielchiieva
              Paul Rogers Paul Rogers
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: