phoenix-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Nick Dimiduk <ndimi...@gmail.com>
Subject Re: REG: using between for dates
Date Tue, 19 Jan 2016 22:04:35 GMT
What version of Phoenix are you using? You're probably hitting PHOENIX-2611.

On Wed, Dec 23, 2015 at 1:12 AM, Ns G <nsgnsg84@gmail.com> wrote:

> Hi Team,
>
> I want to fetch records with  date column between current date and a past
> date.
> Currently when i use between in phoenix it is not working.
>
> Can any one help?
>
> Query:
>
> SELECT id,to_date(SUBSTR(ID2, (LENGTH(ID2)-7), 8),'yyyyMMdd','GMT') FROM
> table1 h WHERE to_date(SUBSTR(ID2, (LENGTH(ID2)-7), 8),'yyyyMMdd','GMT')
> between current_date() and (current_date()-2000)
>
> RESULT:
>
>  Empty result set fetched
>
>
> Thanks,
> Ns
>
> PS: Valid data exists in the table to satisfy the query.
>
>
>

Mime
View raw message