How can I convert Unix TimeStamp data to datetime format (dd/mm/yyyy)?

I have in my Mysql database a table with the data values in Unix TimeStamp (milliseconds). Is there any form of conversion so that when displaying the query results it appears in the data format dd / mm / yyyy?

For example, I want to program an indicator of processes started per month, so I need to count all the processes in my database for each of the 12 months of the year. The user can select a month of interest, in which case the number of processes initiated per day (0 - 31) for that month must appear.

I believe that the first step is to convert the Unix format to date and after working with these to perform counting and filters.

Hi @J_trida
You can change Field Type to “UNIX Timestamp” in Admin > Data Model > (database) > (table) > (column), which will make the field show as regular datetime field.
https://www.metabase.com/docs/latest/administration-guide/03-metadata-editing.html
But it’s recommended to convert your database column to datetime instead of UNIX timestamp.

1 Like

This answer does not include my doubt. I am not interested in the data display format, but in the operations carried out on them.

I believe my question is more specific to SQL programming functions, since I have data in the Unix TimeStamp type, but in the result of my operations I want to display it in the date format.
The case I’m trying to solve is to count the number of processes initiated for each month (regardless of the year), that is:

month   count
Jan       23
Feb       18
mar       45
apr       16
may       54
jun       48
July      32
aug       36
sept      22
oct       08
nov       12
dec       18

The big problem I have is not being able to identify the starting month, because my date is in the Unix TimeStamp format (milliseconds - type/BigInt). If you have seen something similar or know a solution and possible to share, thank you.

@J_trida You should use stackoverflow.com or similar forum dedicated to the database you’re using, since it is not related to Metabase - they will be able to provide much better help.