Say I have a column that contains unix timestamps - an int representing the number of seconds since the epoch. They look like this: 1347085827. How do I format this
1347085827
Postgresql has a handy built-in function for this: to_timestamp(). Just wrap that function around the column you want:
to_timestamp()
Select a, b, to_timestamp(date_int) FROM t_tablename