https://questdb.io logo
Title
a

Ajay Pilaniya

12/03/2022, 3:54 PM
Does quest supports milli seconds timestamp during insert and select queries (in where clause)??
a

Andrey Pechkurov

12/03/2022, 4:56 PM
Hi Ajay, Could you clarify what you mean by "using milli second timestamp"? Do you refer to timestamp literals? If so, yes you can use millisecond precision there:
select * from trades where timestamp >= '2022-03-08T18:03:57.609Z';
Note that timestamp are stored in microsecond precision, so if you insert a
2022-03-08T18:03:57.609Z
timestamp, it's stored as if it was
2022-03-08T18:03:57.609000Z
a

Ajay Pilaniya

12/05/2022, 4:54 AM
@Andrey Pechkurov Is it possible to use epoch timestamps directly?
a

Andrey Pechkurov

12/05/2022, 6:28 AM
You can do so if you use `cast`:
cast(my_ts_value as timestamp)