How to explain date type


#1

select sssj,t.* from ele_measure_201811 t where t.SSSJ IN (‘2018-11-01’).
why the sql no record?
sssj is date type field.
how to select the ture result?
i have only little data about mapD.

With Regards
tracy.


#2

use extract function,
how to explain it (1541001600、1541030400) , and how to select the ture result ,
EPOCH means what?


#3

Hi @tracysw

You can write your query like this:
select sssj, t.* from ele_measure_201811 t where CAST(t.SSSJ as DATE) = ‘2018-11-01’

On your question on EPOCH:
Unix EPOCH is the number of seconds that have elapsed since January 1, 1970 (midnight UTC/GMT). Therefore, the unix time stamp is merely the number of seconds between a particular date and the Unix Epoch.

Regards,
Veda