Uploaded image for project: 'Apache Drill'
  1. Apache Drill
  2. DRILL-4645

Regex_replace() function is broken

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • None
    • None
    • Functions - Drill
    • None

    Description

      git.commit.id.abbrev=5705d45

      select regexp_replace(cast(columns[2] as VARCHAR(4)), 'a', 'b') from `t1.csv` limit 2;
      ------------------------------------------------------------------

      EXPR$0

      ------------------------------------------------------------------

      org.apache.drill.exec.expr.fn.impl.CharSequenceWrapper@7a6e1b48
      org.apache.drill.exec.expr.fn.impl.CharSequenceWrapper@7a6e1b48

      ------------------------------------------------------------------

      Content of table t1.csv:

      select * from `t1.csv`;
      ------------------------------

      columns

      ------------------------------

      ["1","aaaaa","2015-01-01"]
      ["2","bbbbb","2015-01-02"]
      ["3","ccccc","2015-01-03"]
      ["4","","2015-01-04"]
      ["5","eeeee","2015-01-05"]
      ["6","fffff","2015-01-06"]
      ["7","ggggg","2015-01-07"]
      ["","hhhhh","2015-01-08"]
      ["9","iiiii",""]
      ["10","jjjjj","2015-01-10"]

      ------------------------------

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              knguyen Krystal
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated: