Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

206
Views
Trino/Presto: How to convert a timestamp to a bigint in milliseconds

I have the following SQL:

 select cast(to_unixtime(date_trunc('hour', current_timestamp)) AS bigint);

Basically I always go back to the beginning of the time, take that timestamp and try to get the Unix time.

However, this is printing a value like this, which is in seconds: 1708473600 but I want it to be in milliseconds, something like 1708473600000 .

I can't seem to find an example in the Trino documentation on how to do this. They have a to_millisecond method that takes an interval. I just want to provide a timestamp and get the unix epoch time in ms.

over 2 years ago · Carlos Garzón Colorado
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!