Uploaded image for project: 'Hive'
  1. Hive
  2. HIVE-3108

SELECT count(DISTINCT col) ... returns 0 if "col" is a partition column

    Details

    • Type: Bug
    • Status: Reopened
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: 0.8.0, 0.9.0
    • Fix Version/s: None
    • Component/s: Query Processor
    • Labels:
    • Environment:

      Mac OSX running Apache distribution of hadoop and hive natively.

      Description

      Suppose "stocks" is a managed OR external table, partitioned by "exchange" and "symbol". "count(DISTINCT x)" returns 0 for either "exchange", "symbol", or both:

      hive> SELECT count(DISTINCT exchange), count(DISTINCT symbol) from stocks;
      0 0

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                deanwampler Dean Wampler
              • Votes:
                0 Vote for this issue
                Watchers:
                5 Start watching this issue

                Dates

                • Created:
                  Updated: