hive-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sergey Shelukhin (JIRA)" <>
Subject [jira] [Commented] (HIVE-5679) add date support to metastore JDO/SQL
Date Wed, 30 Oct 2013 00:41:25 GMT


Sergey Shelukhin commented on HIVE-5679:

discussed a little bit here... it looks like support will have to be added to Filter.g.
I had an idea to change the code that converts hive expression to filter-g-expression in metastore
to bypass the string stage and just go directly from one tree to another; that way noone would
need to bother with Filter.g for new features. But that would mean this feature (and others
on top) won't work for getPartitionsByFilter, so not for HCat or Pig or whoever uses that
So filter.g will have support for "date 'foo'" and cast syntax.
>From that, or by looking at column type in case of a string literal (the same way hive
parser does), Metastore would figure out what compares are to be done by date. Both mysql
and postgres support "date 'string'" syntax, so that can be used. But, given how we store
dates in the table, we can just use string compares on metastore side. It will also make it
usable by JDO, otherwise JDO pushdown cannot be added. That way the only problem is to make
sure the date actually gets to metastore. We might not even need to validate it because if
it's an invalid literal parser would catch it.

> add date support to metastore JDO/SQL
> -------------------------------------
>                 Key: HIVE-5679
>                 URL:
>             Project: Hive
>          Issue Type: Improvement
>            Reporter: Sergey Shelukhin
>            Assignee: Sergey Shelukhin
> Metastore supports strings and integral types in filters.
> It could also support dates.

This message was sent by Atlassian JIRA

View raw message