Reply
Highlighted
Explorer
Posts: 16
Registered: ‎05-22-2016

[Phoenix] date column value does not compare properly.

[ Edited ]

Dear all.

 

Is there anyone who knows why below query return null?

 

0: jdbc:phoenix:lctsthb1502:2181> select count(operated) as cnt from user_history where operated between to_date('2015-02-24') and to_date('2015-02-24 00:10') ;
+------+
| CNT |
+------+
+------+

 

Actually the count is 21915.

I can show you the count as like below.

 

0: jdbc:phoenix:lctsthb1502:2181> select count(operated) as cnt from user_history where operated between to_date('2015-02-24 00:00:00.001') and to_date('2015-02-24 00:10') ;
+--------+
| CNT |
+--------+
| 21915 |
+--------+
1 row selected (0.197 seconds)

 

phoenix version is 4.7

 

Thanks in advance

Announcements

Currently incubating in Cloudera Labs:

Envelope
HTrace
Ibis
Impyla
Livy
Oryx
Phoenix
Spark Runner for Beam SDK
Time Series for Spark
YCSB