What value should I choose as length for timestamp without timezone in PostgreSQL?
It's not the &quot;length&quot;, it's the precision of the timestamp, so it controls the fractional seconds (milliseconds, microseconds) you can store.
e.g. '2020-12-14 23:14:10.123456'::timestamp(0) returns 2020-12-14 23:14:10 and '2020-12-14 23:14:10.123456'::timestamp(3) returns 2020-12-14 23:14:10.123
As you get a unix epoch which has no fractional seconds, timestamp(0) should be OK.
But in the end it doesn't matter, as changing the precision doesn't change the storage requirements. It's always 8 byte regardless of the precision you choose.