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

MAXDIR - Unsupported operation exception // partition explorer interface?

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • 1.10.0
    • None
    • Client - JDBC
    • None

    Description

      Using MAXDIR in drill seems to cause errors when trying to apply other standard where clause filters. Am I doing something wrong here?

      *This Query Fails*

      SELECT epoch_hour, entity, `1_average`, `1_95p`
      FROM dfs.`/path/drill-hour-final/`
      where
      dir0 = '2018' and dir1 = '01' and dir2 = '27'
      and dir3 = MAXDIR('dfs', concat('/path/drill-hour-final/',
      dir0, '/', dir1, '/', dir2, '/'))
      and entity = 1784928

      *With This Error*

      > SYSTEM ERROR: UnsupportedOperationException: The partition explorer
      > interface can only be used in functions that can be evaluated at
      > planning time. Make sure that the planner.enable_constant_folding
      > configuration option is set to true.
      >
      > Fragment 1:7
      >
      > [Error Id: d62c8227-db0e-4d31-9443-e570193d1010 on
      > psclxcpdevsys13.nomura.com:31010]

      *Wrapping it Makes it Work Without Error*

      select * from (
      SELECT epoch_hour, entity, `1_average`, `1_95p`
      FROM dfs.`/path/drill-hour-final/`
      where
      dir0 = '2018' and dir1 = '01' and dir2 = '27'
      and dir3 = MAXDIR('dfs', concat('/path/drill-hour-final/',
      dir0, '/', dir1, '/', dir2, '/'))
      ) where entity = 1784928

      epoch_hour entity 1_average 1_95p
      1517086800 1784928 5.334722222222222 8.82857142857143
      1517014800 1784928 25.944984717977217 40.37453087409783

      Attachments

        1. maxdir_fail.json
          45 kB
          John Humphreys
        2. maxdir_success.json
          86 kB
          John Humphreys

        Activity

          People

            Unassigned Unassigned
            john.humphreys John Humphreys
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: