I have a field which its format is date with time as: YYYY-MM-DD HH-MM-SS
for example: 2000-08-12 00:00:00
I want to get just the date part and change its format to DD/MMM/YYYY
for example the expected result of the previous example will be: 12/Aug/2000
The field definition is: Ddate timestamp without time zone DEFAULT now()
I read the whole page of Date/Time Functions and Operators and other sources as well but I couldn't find any information that is helpful.
You can use the
to_char
function to format your column: