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

Inner joins that have no results do not return any metadata

    Details

      Description

      When executing the query

      SELECT `time_table`.`column1` AS `columnB`,
        `emp`.`date_hire` AS `date_hire`,
        `emp`.`dept` AS `dept`,
        `emp`.`emp_id` AS `emp_id`,
        `emp`.`first_name` AS `first_name`,
        `emp`.`interests` AS `interests`,
        `time_table`.`keycolumn` AS `keycolumn`,
        `emp`.`last_name` AS `last_name`,
        `emp`.`log_exempt` AS `log_exempt`,
        `emp`.`num_salary` AS `num_salary`
      FROM `hive43.default`.`emp` `emp`
        INNER JOIN `hive43.default`.`time_table` `time_table` ON (`emp`.`last_name` = `time_table`.`column1`)
      LIMIT 10000
      

      the expected result is 0 rows. Sqlline returns this:

      +--+
      |  |
      +--+
      +--+
      No rows selected (1.868 seconds)
      

      However, the recordbatch coming back has no metadata in them. They should at least come back with the column names and types.

        Activity

        Hide
        overcoil George Chow added a comment -

        This style of query is used by Tableau when using 'Multiple tables'.

        Show
        overcoil George Chow added a comment - This style of query is used by Tableau when using 'Multiple tables'.
        Hide
        norrisl Norris Lee added a comment -
        Show
        norrisl Norris Lee added a comment - Fixed with the https://issues.apache.org/jira/browse/DRILL-884 patch.

          People

          • Assignee:
            sphillips Steven Phillips
            Reporter:
            norrisl Norris Lee
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development